Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 4 of 4
  1. #1
    New Coder
    Join Date
    Jun 2011
    Posts
    15
    Thanks
    5
    Thanked 0 Times in 0 Posts

    Analytics event tracking in XML

    Hi

    I have a problem because im not a XML pro I want to use this tracking code:

    Code:
    onclick="_gaq.push(['_trackEvent', 'navigation', 'link', '2011']);
    In theese two XML link tags:

    Code:
    <?xml version="1.0" encoding="utf-8"?>
    
    <photos path="images/">
    
    
    <photo name="01" url="1.jpg"  link ="http://www.stark.dk/SelvByg/Tema/Nyt-tag/Staltag-giver-muligheder/">1</photo>
    
    <photo name="02" url="2.jpg"  link ="http://www.stark.dk/skalcem_multipuds_video">2</photo>
    
    </photos>
    But i dont know th e syntax for it. Can somebody please help me, then I would be really happy and thank you a lot

  • #2
    Moderator
    Join Date
    May 2002
    Location
    Hayward, CA
    Posts
    1,453
    Thanks
    1
    Thanked 21 Times in 19 Posts
    Uh, you're in trouble. XML itself has no onclick event handlers, as it's primarily a data exchange format. More to the point, your XML document doesn't have any JavaScripts in it, so there's no "_gaq" object defined in the document's scope.

    How are you planning to load this document?
    "The first step to confirming there is a bug in someone else's work is confirming there are no bugs in your own."
    June 30, 2001
    author, Verbosio prototype XML Editor
    author, JavaScript Developer's Dictionary
    https://alexvincent.us/blog

  • #3
    New Coder
    Join Date
    Jun 2011
    Posts
    15
    Thanks
    5
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by Alex Vincent View Post
    How are you planning to load this document?
    Im planning to use it with Flash. I have a flash rotator with some products and on these products I want the tracking code. Guess this is the wrong forum then

  • #4
    Moderator
    Join Date
    May 2002
    Location
    Hayward, CA
    Posts
    1,453
    Thanks
    1
    Thanked 21 Times in 19 Posts
    Flash devs: can you help our colleague out here? Maybe you know something I don't.
    "The first step to confirming there is a bug in someone else's work is confirming there are no bugs in your own."
    June 30, 2001
    author, Verbosio prototype XML Editor
    author, JavaScript Developer's Dictionary
    https://alexvincent.us/blog


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •