Jump to content

removing cdata code


shervanf

Recommended Posts

hello

i have some problems

i want to add some codes in header.tpl but presta changes my codes by adding cdata to that.

how can i remove that code????

this is my original codes:

<script type="text/javascript"> var script = document.createElement("script"); script.src = 'http://www.mitrarank.ir/search/5787b62485c53/' + encodeURIComponent(document.referrer); script.type="text/javascript"; document.getElementsByTagName("head")[0].appendChild(script); </script>

but my site shows:

<script type="text/javascript">/* <![CDATA[ */;var script=document.createElement("script");script.src='http://www.mitrarank.ir/search/5787b62485c53/'+encodeURIComponent(document.referrer);script.type="text/javascript";document.getElementsByTagName("head")[0].appendChild(script);/* ]]> */</script>
Edited by shervanf (see edit history)
Link to comment
Share on other sites

i tried these solutions

:1.by adding code directly in header.tpl in theme file

2. using theme widget in my theme

i put those script below the <header>

but it doesnt work.

it affects my code because developer site says : they didnt find their code in my site.

Link to comment
Share on other sites

I do not think /*<![CDATA[*/ and /* ]]> */ will affect because they are all commented out. it must be your code itself.

 

Or you can change CCC setting to disable all minimisation or cache options to see if the cdata will disappear or not - back office - Advanced Parameters - Performances tab.

if you disable all those options, then it should be output as is - what you entered in your theme file.

 

 

 

 

 

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...