Redirect

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • jonathanthio@yahoo.com.sg

    #1

    Redirect

    Hi,

    I have a script called rd.js stored in http://nudelivelady.com/naked

    It contains one line

    this.location = "http://naked.nudelivel ady.com"

    Now, many websites access that script. Any website that access that
    script will be redirected to http://naked.nudelivelady.com

    The problem is I don't know which websites access that script. Because
    when I check the webstats, the referrer is not noted due to the
    redirect.

    For example,
    http://domain.com/blabla.htm

    redirects to http://naked.nudelivelady.com

    However, if I check the referrers in webstats, I wouldn't see
    http://domain.com/blabla.htm

    How should I modify rd.js so I can see the referrer?

  • commercial

    #2
    Re: Redirect

    "webstats" are client or server scripts just what you ask for.

    You problems seems to be less of a proficiency question
    but more of an obsession with results of images loading etc.

    And that is worth nothing. What are you capable of ?

    Children with 2 heads and 3 arms ?






    <jonathanthio@y ahoo.com.sg> wrote in message
    news:1116994801 .442461.112980@ z14g2000cwz.goo glegroups.com.. .[color=blue]
    > Hi,
    >
    > I have a script called rd.js stored in http://nudelivelady.com/naked
    >
    > It contains one line
    >
    > this.location = "http://naked.nudelivel ady.com"
    >
    > Now, many websites access that script. Any website that access that
    > script will be redirected to http://naked.nudelivelady.com
    >
    > The problem is I don't know which websites access that script. Because
    > when I check the webstats, the referrer is not noted due to the
    > redirect.
    >
    > For example,
    > http://domain.com/blabla.htm
    >
    > redirects to http://naked.nudelivelady.com
    >
    > However, if I check the referrers in webstats, I wouldn't see
    > http://domain.com/blabla.htm
    >
    > How should I modify rd.js so I can see the referrer?
    >[/color]

    Comment

    • Grant Wagner

      #3
      Re: Redirect

      <jonathanthio@y ahoo.com.sg> wrote in message
      news:1116994801 .442461.112980@ z14g2000cwz.goo glegroups.com.. .[color=blue]
      > Hi,
      >
      > I have a script called rd.js stored in http://nudelivelady.com/naked
      >
      > It contains one line
      >
      > this.location = "http://naked.nudelivel ady.com"
      >
      > Now, many websites access that script. Any website that access that
      > script will be redirected to http://naked.nudelivelady.com[/color]

      websites parse and execute the client-side JavaScript you are including?
      Interesting. If you mean that Web sites contain links to that resource
      that people click on, then you are depending on them having client-side
      JavaScript enabled for your code to work.
      [color=blue]
      > The problem is I don't know which websites access that script. Because
      > when I check the webstats, the referrer is not noted due to the
      > redirect.
      >
      > For example,
      > http://domain.com/blabla.htm
      >
      > redirects to http://naked.nudelivelady.com
      >
      > However, if I check the referrers in webstats, I wouldn't see
      > http://domain.com/blabla.htm
      >
      > How should I modify rd.js so I can see the referrer?[/color]

      The HTTP REFERER is sent at the whim of the user agent, there is no
      requirement for any user agent to ever send you a REFERER, or if it does
      send you a REFERER, that it is the correct one.

      Anyway, the solution is not to "fix" the client-side JavaScript, the
      solution is to fix your server so that requests to
      http://yourdomain.com/somepath translates to
      http://somepath.yourdomain.com.

      This could be accomplished using virtual servers or mod_rewrite in
      Apache for example. Either of those solutions should preserve whatever
      REFERER the user agent chooses to send you.

      --
      Grant Wagner <gwagner@agrico reunited.com>
      comp.lang.javas cript FAQ - http://jibbering.com/faq


      Comment

      Working...