wood burning stoves 2.0*
The moose likes Servlets and the fly likes Ensure correct sequence of printing of request parameters ? 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 » Java » Servlets
Bookmark "Ensure correct sequence of printing of request parameters ?" Watch "Ensure correct sequence of printing of request parameters ?" New topic
Author

Ensure correct sequence of printing of request parameters ?

Rahul Sudip Bose
Ranch Hand

Joined: Jan 21, 2011
Posts: 637

I used an enumeration to store request parameters sent to a servlet by a html form. These are not printed in the order in which they appeared in the html form. How to get the correct order ?

SCJP 6. Learning more now.
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18541
    
    8

Put them into the enumeration in the correct order.

And "correct" is your word for it. Don't expect anything in the servlet container to know what you mean by that. That means that you'll have to write code which does things correctly.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60785
    
  65

There is no guarantee that the parameters will be sent to the server in any specific order. If your application depends upon this, prepare for endless problems as the order can be anything.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Ensure correct sequence of printing of request parameters ?
 
Similar Threads
Sequence of request parameters
New to servlets&JSP
order of retreiving form parameters using javascript
A diffrent problem on request attributes
jsp:param more deatils needed