I was reviewing #4509 and was playing with @indigoxela's PR on my local, trying to conditionally show/hide a warning if webp
was added to the list of allowed extensions for an image field instance.
A condition like this, where the value is "static" works fine:
'#states' => array(
'visible' => array(
':input[name="instance[settings][file_extensions]"]' => array('value' => 'png, gif, jpg, jpeg, webp'),
),
),
But the goal is to check the value of the field for any occurrence of webp
. Unfortunately, #states
doesn't seem to support regex OOTB
With some research, I've found this article: https://evolvingweb.ca/blog/extending-form-api-states-regular-expressions which would allow something like this:
'#states' => array(
'visible' => array(
':input[name="instance[settings][file_extensions]"]' => array('regex' => array('value' => '^.*webp.*$')),
),
),
Recent comments
Thank you for all your help. In the meantime I just edited the export db-file and removed the top line with the sandbox comment. --> Still the same issue. I exported also with the...
Problem with utf8mb4 Format when importing database
Another possibility: The RRSB module has a forward option. If you don't want all the social-media sharing links, you can uncheck them all, then enable RRSB on the node types of your choice.
Forward/email this page ?
One person said: I use bee in mamp - but not sure what i can offer. I did a basic setup and it just works...
Problem with utf8mb4 Format when importing database