Jump to content

Error after installing a script


WorldOfNuts

Recommended Posts

Hi

 

I have a cloud solution and after i have got a user on getsitecontrol.com, i have to add a script code, just before the </body> tag, but every time i do that i get a blank frontpage, its like the site can´t be loaded.

 

the script is:

 

<script>
  (function (w,i,d,g,e,t,s) {w[d] = w[d]||[];t= i.createElement(g);
    t.async=1;t.src=e;s=i.getElementsByTagName(g)[0];s.parentNode.insertBefore(t, s);
  })(window, document, '_gscq','script','//widgets.getsitecontrol.com/43596/script.js');
</script>

 

can anyone help me?

what should i do to get it to work?

Edited by WorldOfNuts (see edit history)
Link to comment
Share on other sites

This is solved. the problem was that i edited the tpl file and thats not allowed on a cloud solution.

 

 

what? it is possible to edit .tpl files on cloud.

problem you had was related probably to fact that you used braces, and smarty treats code with braces as a smarty syntax

to avoid that use {literal} {/literal} tags, put the code with braces inside.

{literal}
<script>
  (function (w,i,d,g,e,t,s) {w[d] = w[d]||[];t= i.createElement(g);
    t.async=1;t.src=e;s=i.getElementsByTagName(g)[0];s.parentNode.insertBefore(t, s);
  })(window, document, '_gscq','script','//widgets.getsitecontrol.com/43596/script.js');
</script>
{/literal}
Link to comment
Share on other sites

  • 8 months later...

 

what? it is possible to edit .tpl files on cloud.

problem you had was related probably to fact that you used braces, and smarty treats code with braces as a smarty syntax

to avoid that use {literal} {/literal} tags, put the code with braces inside.

{literal}
<script>
  (function (w,i,d,g,e,t,s) {w[d] = w[d]||[];t= i.createElement(g);
    t.async=1;t.src=e;s=i.getElementsByTagName(g)[0];s.parentNode.insertBefore(t, s);
  })(window, document, '_gscq','script','//widgets.getsitecontrol.com/43596/script.js');
</script>
{/literal}

Unfortunately, this doesnt helps also..

Inserted it in footer.tpl, right before the </body> tag.

 

Is there anything else i can do?

Using PS 1.6.1.8.

Edited by loetje88 (see edit history)
Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...