Meaningless Drivel is fun!*
The moose likes HTML, CSS and JavaScript and the fly likes Hiding the value from URL Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Hiding the value from URL" Watch "Hiding the value from URL" New topic
Author

Hiding the value from URL

Yed Su
Greenhorn

Joined: Mar 02, 2011
Posts: 10

In the list page of my application I have the edit link as follows beside each row in a list:



But the value of 'id' is being seen on the url when clicked on the link.

Is there a way to suppress/hide the id value from the url.

Regards,
Sudheer
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60806
    
  65

Not with a link. But why bother? If it's for security, then you are barking up the wrong tree.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Yed Su
Greenhorn

Joined: Mar 02, 2011
Posts: 10

Apologies! there was no clear description of the problem in my earlier post.

This post is related to spring mvc. As my intent was to be redirected with a click on a link in my list page to edit page, I wanted to pass a parameter- an id which distinguishes the row in a list to my controller via a href. I can achieve this as below:


But the value is visible in the url which is a concern to me. Is there any other approach for the above? Simply, I want to know how I can pass a single parameter our of a bunch of values from my list(view) to the controller.
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18541
    
    8

Yed Su wrote:But the value is visible in the url which is a concern to me.


And why is that?
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60806
    
  65

Yed Su wrote:This post is related to spring mvc

There is nothing Spring-specific about what you are asking so we'll keep the discussion here in the HTML forum.

But the value is visible in the url which is a concern to me.

I'll reiterate for the 3rd time in this topic: why?

Again, if it's security then you're approaching the problem incorrectly. And if it is security, what security issue are you concerned about?
 
Consider Paul's rocket mass heater.
 
subject: Hiding the value from URL
 
Similar Threads
Consuming a .NET Typed DataSet from Java
Knowning which link was clicked (take 2)
Displaying a link using display tag.
Hyper link in JSF
[struts 2] Use Javascript confirm() dialog