Javascript error with the subscription form
-
Hi,
I use Tribulant Newsletters Pro 4.5.6.2 on WordPress 4.4.1.
I’ve just noticed today while investigating SSL deployment, that the javascript code that goes with the subscription form shortcode causes an error in browser (seen it in Safari, Firefox and Chrome):
in Chrome: “Uncaught SyntaxError: Unexpected token <“
in Firefox: SyntaxError: expected expression, got ‘<‘
in Safari: SyntaxError: Unexpected token ‘<‘The code snippet that’s been highlighted is the first line after <script> :
<p><script type="text/javascript"> jQuery(document).ready(function() {</p> <p> if (jQuery.isFunction(jQuery.fn.select2)) { jQuery('.newsletters select').select2(); }</p> <p> jQuery('input:not(:button,:submit),textarea,select').focus(function(element) { jQuery(this).removeClass('wpmlfielderror').nextAll('div.newsletters-field-error').slideUp(); });</p> <p> jQuery('.newsletters-management .newsletters-fieldholder, .entry-content .newsletters-fieldholder, .post-entry .newsletters-fieldholder, .entry .newsletters-fieldholder').addClass('col-md-6'); }); </script>
the form is added with shortcode:
[newsletters_subscribe list=”6″]and the error only appear on pages that has this shortcode.
Thanks
R.
Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
- The topic ‘Javascript error with the subscription form’ is closed to new replies.