Robin S Posted November 19, 2016 Share Posted November 19, 2016 Image & File Dependencies Allows Image and File fields to be used in inputfield dependency selectors. Note: prefix field names with an underscore in your dependency selectors. Usage Install the ImageFileDependencies module. You can now create an inputfield dependency based on the number of images or files added to a Image or File field. When you create an inputfield dependency for a Image or File field, prefix your field name with an underscore. Example for a field named 'images': _images>3 Note that you do not include a '.count' subfield in the selector. https://github.com/Toutouwai/ImageFileDependencies Demo 14 Link to comment Share on other sites More sharing options...
szabesz Posted November 20, 2016 Share Posted November 20, 2016 Oh yes, this is great! Thanks for sharing 1 Link to comment Share on other sites More sharing options...
Robin S Posted November 20, 2016 Author Share Posted November 20, 2016 @szabesz, glad you approve. I have plans for another module relating to inputfield dependencies. Watch this space. 1 Link to comment Share on other sites More sharing options...
owzim Posted November 20, 2016 Share Posted November 20, 2016 @Robin S looks great, thanks. Can you name a use case? On a side note: What are you using to record the screen and export to gif? I tried gifrocket, but even with a small framerate, files get pretty large. Yours is tiny, I like it. 1 Link to comment Share on other sites More sharing options...
szabesz Posted November 20, 2016 Share Posted November 20, 2016 24 minutes ago, owzim said: What are you using to record the screen and export to gif? Maybe this one (LICEcap)? 1 Link to comment Share on other sites More sharing options...
Robin S Posted November 20, 2016 Author Share Posted November 20, 2016 1 hour ago, owzim said: Can you name a use case? The use cases are the same as those for any inputfield dependency: you want to show or require one field based on the state of another. This module just adds Image and File fields to the types of fields you can use in an inputfield dependency selector. Off the top of my head: you have an images field for an optional gallery and you want to remind the site editor to add a summary/introduction for the gallery if images are added. Also, there was this request for help. @szabesz is right - the screen recorder tool is LICEcap. I discovered it via this post by @bernhard. 4 Link to comment Share on other sites More sharing options...
alexcapes Posted November 21, 2016 Share Posted November 21, 2016 @Robin S you're my hero again for this module! Seriously every time I think of something I need in PW you're already on it. 5 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now