HTTP_referer

Discussion in 'Java' started by lardy ninja, Sep 29, 2003.

  1. lardy ninja

    lardy ninja Guest

    I'm using a URLConnection object to connect to a website. Can anyone
    tell me how to pass different values for the HTTP_referer variable to
    this site?

    TIA

    LN.
     
    lardy ninja, Sep 29, 2003
    #1
    1. Advertising

  2. lardy ninja

    Steven Coco Guest

    lardy ninja wrote:
    > I'm using a URLConnection object to connect to a website. Can anyone
    > tell me how to pass different values for the HTTP_referer variable to
    > this site?


    Before you call connect() on your URLConnection, you should just have to
    call the setRequestProperty method with your key/value pair.

    This field is not outlined in RFC 2616; so be sure about your spelling,
    format, etc.

    Good luck.

    --

    ..Steven Coco.
    .........................................................................
    When you're not sure:
    "Confess your heart" says the Lord, "and you'll be freed."
     
    Steven Coco, Oct 2, 2003
    #2
    1. Advertising

  3. On Wed, 01 Oct 2003 23:38:38 GMT, Steven Coco wrote:
    > This field is not outlined in RFC 2616; so be sure about your
    > spelling, format, etc.


    Isn't this what he means?

    http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.36

    Or is "HTTP_referer" something different?

    /gordon

    --
    [ do not email me copies of your followups ]
    g o r d o n + n e w s @ b a l d e r 1 3 . s e
     
    Gordon Beaton, Oct 2, 2003
    #3
  4. lardy ninja

    lardy ninja Guest

    Gordon Beaton <> wrote in message news:<3f7bda1e$>...
    > On Wed, 01 Oct 2003 23:38:38 GMT, Steven Coco wrote:
    > > This field is not outlined in RFC 2616; so be sure about your
    > > spelling, format, etc.

    >
    > Isn't this what he means?
    >
    > http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.36
    >
    > Or is "HTTP_referer" something different?
    >
    > /gordon



    Yes that's correct. Can I pass this through a Java call?

    LN
     
    lardy ninja, Oct 2, 2003
    #4
  5. On 2 Oct 2003 13:40:19 -0700, lardy ninja wrote:
    > Yes that's correct. Can I pass this through a Java call?


    Like Steven already said: use setRequestProperty() before calling
    connect().

    /gordon

    --
    [ do not email me copies of your followups ]
    g o r d o n + n e w s @ b a l d e r 1 3 . s e
     
    Gordon Beaton, Oct 2, 2003
    #5
  6. lardy ninja

    lardy ninja Guest

    Gordon Beaton <> wrote in message news:<3f7c8f8d$>...
    > On 2 Oct 2003 13:40:19 -0700, lardy ninja wrote:
    > > Yes that's correct. Can I pass this through a Java call?

    >
    > Like Steven already said: use setRequestProperty() before calling
    > connect().
    >
    > /gordon



    Thank you both for your help.

    LN.
     
    lardy ninja, Oct 3, 2003
    #6
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Elliot M. Rodriguez
    Replies:
    1
    Views:
    663
    bruce barker
    Feb 12, 2004
  2. SStory

    HTTP_REFERER blank

    SStory, Feb 27, 2004, in forum: ASP .Net
    Replies:
    1
    Views:
    2,420
    Eric Lawrence [MSFT]
    Feb 28, 2004
  3. =?Utf-8?B?cHBhdGVs?=

    Request.ServerVariables ("HTTP_REFERER") using https

    =?Utf-8?B?cHBhdGVs?=, Mar 2, 2004, in forum: ASP .Net
    Replies:
    1
    Views:
    3,590
    Eric Lawrence [MSFT]
    Mar 3, 2004
  4. Troy

    Hit redirection & HTTP_REFERER

    Troy, Jun 24, 2004, in forum: ASP .Net
    Replies:
    1
    Views:
    632
    Joerg Jooss
    Jun 26, 2004
  5. John

    Getting HTTP_REFERER value

    John, Oct 6, 2004, in forum: ASP .Net
    Replies:
    2
    Views:
    840
Loading...

Share This Page