Let me say at the onset, I know my code is wrong. I need some help. I have tried searching the internet for answers and figured it was time to get on a forum and ask for help.
I participate with Google Analytics. It’s great. I am able to add code like
[code]onClick=”javascript:urchinTracker (‘/download/audiofile1’);”
to a link and it will track that action so that I know how often a file on my HTML site has been downloaded.
The problem is, what if you are using buttons that have rollovers and there is already an onClick in place? How do you add Google’s code to what you already have to get both to work? I am not a novice with javascript, but I am also not a pro, so I need some help on this one. Here’s my code (and I have the standard rollover javascript that Fireworks 8 outputs – it’s linked in as a separate .js file rather than right in the HTML document):
[code]<a href=”../assets/mp3_clips/audioclip1.mp3″ onmouseout=”MM_swapImgRestore()” onmouseover=”MM_swapImage(‘sr_nav_r3_c4′,”,’../assets/nav1_f2.gif’,1)” onclick=”javascript:Popup(‘My Audio’,this.href,’1′); return false” “javascript:urchinTracker(‘/download/audio_clip1’)”><img src=”../assets/nav1.gif” alt=”Clip Length: 1 Min. 1 Sec.” name=”nav1″ width=”70″ height=”19″ border=”0″ id=”nav1″ /></a>