PO Michel

[Solved 9r] SyntaxError: unterminated string literal

10 posts in this topic

Hi,

I use BT Slideshow Pro 2.1.5 on a Joomla 2.5.16 installation using the Corporate BD theme.

I get a strange "SyntaxError: unterminated string literal" error on a K2 element including a BT Slideshow Pro module using the {loadposition} shortcode.

This error leads to the following section of the tmpl\style5.php file (I use style5 for the slideshow) :

var structure = '<a href="#" class="prev_button">prev</a>' +

'<a href="#" class="next_button">next</a>' +

'<span class="info_slide"></span>' +

'

<div class="container_skitter">' +

'

Unfortunately, I can't get any support from the theme developer.

URL is : http://contat.alptic-dev.fr/fr/contat-freres-decolletage-usinage-technologies

Any idea ?

Share this post


Link to post
Share on other sites

Hi,

Thanks a lot for your reply.

I have given a try to another module (Showplus) but I have just re-enabled BT SlideShow Pro.

I also have disabled Widgetkit modules which prevent form getting the error mentioned.

Share this post


Link to post
Share on other sites

Hi,

Strange, isnt'it ?

I have so many strange problems with this template ;-)

I use Style5 layout with Responsive and Caption options enabled.

You will get very soon my FTP credentials via MP

Share this post


Link to post
Share on other sites

Hi Michel.

We fixed your problem with a trick.

First, let me say that there is a plugin on your site make this problem. It detects HTML tags on javascript and breaks them.

Example , in Javascript, I initialize a variable as a HTML tag like this

var structure = '<div class=""><a href=""><a/></div>';

The plugin detects i use <div> tag in javascript. It break the line to

var structure = '

<div class=""><a href=""><a/></div>';

So this is a error.

We must use a trick to make the plugin can not detect HTML in the script. Example we use concatenate string to divide the "DIV" to "DI" and "V". The plugin can not detect HTML tag in this case.

var structure = '<di' + 'v class=""><a href=""><a/></di' + 'v>';

So, it is hard to understand with persons who don't know javascript :D

Not important, now the slideshow is running.

Please notice backup the style5.php file, when you want to upgrade the module.

Regards

Share this post


Link to post
Share on other sites

Hi,

Thanks a lot for your excellent support.

As you mentioned, there are plenty of extensions installed on my site and debugging the one responsible for that behaviour would take long.

I have taken a backup of the style5.php file.

Thanks again.

Share this post


Link to post
Share on other sites