Syntax error, unrecognized expression in Safari
Tuesday, May 23, 2017 at 08:04amI have been using this code:
jQuery("a[data-gal^='prettyPhoto'").prettyPhoto({overlay_gallery: false, social_tools:false, hook: 'data-gal'});
And it is working fine on all browsers except Safari which throws an
Error: Syntax error, unrecognized expression: a[data-gal^='prettyPhoto'
Do you have an advice or an idea of what Safari doesn't like?
Reply to: Syntax error, unrecognized expression in Safari
Tuesday, May 23, 2017 at 08:06amjQuery("a[data-gal^='prettyPhoto']").prettyPhoto({overlay_gallery: false, social_tools:false, hook: 'data-gal'});Other browsers such as Chrome might be more lenient and close the selector. However, it is still a syntax error. Let me know if this works for you.