![]() |
| Home | Demo | Services | Features | Help | User Forum | Blog | About | |
|
#1
|
|||
|
|||
|
Hi All,
How do I embed the statcounter into another set of script tags? Put another way...my current code is as follows and I want to count how often various functions are called i.e. <script blah blah bah> . . function one() { . - call projectone at statcounter from here - } function two() { . - call projecttwo at statcounter from here - } </script> Can this be done? I cant figure out how to embed a set of <script></script> tags within another <script></script> pair. Any insights would be most appreciated |
|
#2
|
||||
|
||||
|
I don't think it will actually work. Haven't tried though.
But in general, to embed a js script into another js script you will need to write the embedded script out using document.write and put all of it inside some quotes (different from those already being used). Do one line at a time or you'll get lost. You have to break apart <script as <scr and then ipt, similarly for </script> . Don't even bother with the noscript portion as it will definitely not apply. You'll also have to probably replace / by \/ and so on. Kind of tedious. And doubtful. For one thing don't expect the page visited nor the referrer to be the script in which you are trying to embed this.
__________________
Christina >>Forum Moderator<< Please do not PM me for support. The forum is here for that. |
![]() |
| Thread Tools | |
| Display Modes | |
|
|