Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. Cross domain tracking [modified]

Cross domain tracking [modified]

Scheduled Pinned Locked Moved Web Development
helpcsharpphpperlasp-net
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • G Offline
    G Offline
    GilbertLiddell
    wrote on last edited by
    #1

    Hi, I have two sites (domain1 asp.net web application and domain2 perl web booking application). Currently, a user clicks a button on domain1 to start their journey, they are then sent to domain2. On domain2 the user clicks a button to complete their journey. This is what I want to do, when the user clicks the button on domain1 to start their journey, a cookie is saved and when the user clicks the button on domain2 to complete their journey the cookie is updated. This will allow me to record how many people who started the journey, completed it. I know cross domain cookies are an issue however i've heard of people using the image tag to get round this problem by placing a hidden image on the pages where the buttons are and setting it's src in script to a page elsewhere. I've seen solutions in php for this but i don't know php and need a .net or classic asp solution. I also need to send the cookie info to a database but thats the easy bit. Any ideas?? -- modified at 4:15 Tuesday 3rd July, 2007

    J 1 Reply Last reply
    0
    • G GilbertLiddell

      Hi, I have two sites (domain1 asp.net web application and domain2 perl web booking application). Currently, a user clicks a button on domain1 to start their journey, they are then sent to domain2. On domain2 the user clicks a button to complete their journey. This is what I want to do, when the user clicks the button on domain1 to start their journey, a cookie is saved and when the user clicks the button on domain2 to complete their journey the cookie is updated. This will allow me to record how many people who started the journey, completed it. I know cross domain cookies are an issue however i've heard of people using the image tag to get round this problem by placing a hidden image on the pages where the buttons are and setting it's src in script to a page elsewhere. I've seen solutions in php for this but i don't know php and need a .net or classic asp solution. I also need to send the cookie info to a database but thats the easy bit. Any ideas?? -- modified at 4:15 Tuesday 3rd July, 2007

      J Offline
      J Offline
      Justin Williams
      wrote on last edited by
      #2

      The image URL should work like any normal ASP.NET page, just set the cookie, probably based upon the GET variables. (Look up Response.Cookies and Request.QueryString.) Using an tag seems a little bit like a hack and therefore I wouldn't guarantee it would be totally future proof though. Instead I would just use a hidden IFrame, which expects a normal HTML source instead of an image. In domain2 you just set your cookie like normal . If clicking the button is what sends the user to domain2, why not skip any cross domain cookie access and just POST the data ala a form to domain2 when they click the button instead of it being a vanilla link. That would seem to me to be the cleanest approach. Domain2 can then set its cookie appropriately based on the POST (see Request.Form).

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups