rocknbil

msg:3686018 | 4:48 pm on Jun 28, 2008 (gmt 0) |
| I'd like to append whatever variable is put in the search box, to the onClick event so I can see it in Google Analytics: |
| Can't you just put the tracker on the search results page? I don't know that you can do this with the urchin, you might get some assistance from the analytics help files.
|
AnonyMouse

msg:3686060 | 6:30 pm on Jun 28, 2008 (gmt 0) |
Thanks for the reply - unfortunately I can't put the tracker on the results page, I have to catch the variable straight from the search form :-(
|
daveVk

msg:3686183 | 1:14 am on Jun 29, 2008 (gmt 0) |
Maybe <input name="searchterm" id="searchBox" type="text"> <input type="submit" name="Submit" value="Submit" onClick="urchinTracker ('/siteSearch_' + document.getElementById( 'searchBox' ).value );" >
|
AnonyMouse

msg:3686436 | 5:58 pm on Jun 29, 2008 (gmt 0) |
Certainly looks about right - I've added it to the form code, now have to wait until it shows up in the Analytics report. Many thanks!
|
AnonyMouse

msg:3686821 | 12:42 pm on Jun 30, 2008 (gmt 0) |
Just to confirm that that did the trick, many thanks!
|
|