Java help - servlets

Discussion in 'Java' started by Rose Girl, Jun 9, 2004.

  1. Rose Girl

    Rose Girl Guest

    Hi

    I am using the response.sendRedirect(url) method. url is path to
    another servlet. Example:

    response.sendRedirect(response.encodeRedirectURL
    ("/EcBugManager/servlet/bugmanager.bugmanager.gui.BugsheetPage?
    type="+bugsheetType+"&page="+page);

    I am using the response.encodeRedirectURL to encode the url as i dont
    want the parameters to be seen in the explorer - address bar.

    ?? But nothing happens, it just returns the same string with all the
    paramteers without being encoded.

    Am i using the correct way to encode the url, or is there another way
    to do it.

    Please, help me on this
    Thanks for your time

    Rose.
     
    Rose Girl, Jun 9, 2004
    #1
    1. Advertising

  2. "Rose Girl" <> wrote in message
    news:...
    > Hi
    >
    > I am using the response.sendRedirect(url) method. url is path to
    > another servlet. Example:
    >
    > response.sendRedirect(response.encodeRedirectURL
    > ("/EcBugManager/servlet/bugmanager.bugmanager.gui.BugsheetPage?
    > type="+bugsheetType+"&page="+page);
    >
    > I am using the response.encodeRedirectURL to encode the url as i dont
    > want the parameters to be seen in the explorer - address bar.
    >
    > ?? But nothing happens, it just returns the same string with all the
    > paramteers without being encoded.
    >
    > Am i using the correct way to encode the url, or is there another way
    > to do it.
    >
    > Please, help me on this
    > Thanks for your time
    >
    > Rose.


    Rose,

    URL encoding is used to translate caracters in the querystring that are not
    allowed (spaces and ampersand and a bunch of others).
    If I remember correctly the space caracter is translated to %20.

    If your concern is privacy, I'd recommend using a Session object to store
    your information, and pass the Session ID on the querystring.
     
    Enrique Madrid, Jun 9, 2004
    #2
    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. Prateeksha Web Services
    Replies:
    0
    Views:
    1,811
    Prateeksha Web Services
    Aug 29, 2003
  2. miko

    java servlets

    miko, Sep 18, 2003, in forum: Java
    Replies:
    0
    Views:
    383
  3. Jochen Fliedner

    literature java servlets / java tv / mhp

    Jochen Fliedner, Nov 27, 2003, in forum: Java
    Replies:
    0
    Views:
    487
    Jochen Fliedner
    Nov 27, 2003
  4. Dan
    Replies:
    7
    Views:
    2,176
    Manivannan Palanichamy
    Jul 8, 2007
  5. Dan
    Replies:
    7
    Views:
    114
    Manivannan Palanichamy
    Jul 8, 2007
Loading...

Share This Page