Results 1 to 4 of 4
  1. #1
    vector_ever is offline Senior Member
    Join Date
    Jul 2013
    Rep Power

    Default Hide particular parameter in the URL

    Hi, is there any way to hide Hide particular parameter in the URL.
    For example, the original URL after the request: http://localhost:8080/building/detai...e=Adam&Id=2457

    In that URL i have 3 parameters Fname(first name), Lname(last name) and Id
    I wish to find a way to get the same request according to those 3 parameters but hide the Id from URL to be like this: http://localhost:8080/building/detai...ohn&Lname=Adam

    PS: i don't want to hide all the parameter as i use POST method (NOT GET).

  2. #2
    Join Date
    Apr 2014
    Rep Power

    Default Re: Hide particular parameter in the URL

    do not send Id parameter

  3. #3
    RamyaSivakanth's Avatar
    RamyaSivakanth is offline Senior Member
    Join Date
    Apr 2009
    Rep Power

    Default Re: Hide particular parameter in the URL

    send as a hidden parameter as a hidden form field

  4. #4
    SurfMan's Avatar
    SurfMan is offline Godlike
    Join Date
    Nov 2012
    The Netherlands
    Rep Power

    Default Re: Hide particular parameter in the URL

    Once you put a value in the page, be it a parameter in GET or a hidden field in a POST will enable the user to modify the value. If you don't want the user to see/modify the value, don't send it to the user.

    If you can't avoid sending the id to the user, create a hash of all the parameters, like md5( salt + Fname + Lname + id ) and include that as a checksum in the URL/form. Once the server receives the data, recreate the checksum from the post/get data and if that's different than the checksum from the user, someone has been dicking about with the data and you can show them a 404 or whatever you like.
    Last edited by SurfMan; 07-18-2014 at 01:11 PM.
    "It's not fixed until you stop calling the problem weird and you understand what was wrong." - gimbal2 2013

Similar Threads

  1. How to Hide cursor
    By priya in forum Java Software
    Replies: 1
    Last Post: 12-09-2010, 10:39 PM
  2. How to hide a control in SWT?
    By lottalava in forum SWT / JFace
    Replies: 11
    Last Post: 10-18-2010, 10:52 AM
  3. How can i hide the menu bar ?
    By Microman in forum CLDC and MIDP
    Replies: 0
    Last Post: 01-18-2010, 01:43 AM
  4. hide column
    By anilkumar_vist in forum Advanced Java
    Replies: 2
    Last Post: 12-13-2009, 06:46 PM
  5. hide one frame under another
    By marodia in forum AWT / Swing
    Replies: 7
    Last Post: 08-25-2009, 02:23 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts