• Tracking stuff on a page

    From bit-naughty@hotmail.com@21:1/5 to All on Tue Jun 27 11:15:59 2017
    I'm just curious - suppose there's a page with ads on it from an ad network, say Google. When the ad is fetched from Google, does it know WHICH PAGE the request came from, ie. which URL? (it would have to, right?)
    When one page is obtained, the browser just gets the index.html file, and then scans that file to get all files it references, right? - so how would a "<img src=www.site.com/pic.jpg" on that page TELL the jpg's server which page that request came from?
    ie. which URL?

    Is this the Referrer header at work? (wouldn't *seem* like it, from whatever I know about it....?) - the Referrer header is for when you CLICK on a link - it tells the new page which URL it came from....?

    Thanks.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Barry Margolin@21:1/5 to bit-naughty@hotmail.com on Wed Jun 28 16:01:06 2017
    In article <8b6a870c-2ae0-4c78-9fe6-b02408ce8b70@googlegroups.com>,
    bit-naughty@hotmail.com wrote:

    I'm just curious - suppose there's a page with ads on it from an ad network, say Google. When the ad is fetched from Google, does it know WHICH PAGE the request came from, ie. which URL? (it would have to, right?)
    When one page is obtained, the browser just gets the index.html file, and then scans that file to get all files it references, right? - so how would a "<img src=www.site.com/pic.jpg" on that page TELL the jpg's server which page that request came from? ie. which URL?

    Is this the Referrer header at work? (wouldn't *seem* like it, from whatever I know about it....?) - the Referrer header is for when you CLICK on a link - it tells the new page which URL it came from....?

    Referer is also sent for images. Basically, any time a URL is accessed
    because of a reference from a web page, the web page's URL is sent as
    the Referer (there some some exceptions: an HTTPS page accessing an HTTP
    image won't send Referer).

    However, ads these days are usually implemented using Javascript, and
    the script has access to the URL of the page.

    --
    Barry Margolin
    Arlington, MA

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)