This week's book giveaway is in the OO, Patterns, UML and Refactoring forum.
We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line!
See this thread for details.
The moose likes Servlets and the fly likes getParameterValues() qestion. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

JavaRanch » Java Forums » Java » Servlets
Bookmark "getParameterValues() qestion." Watch "getParameterValues() qestion." New topic

getParameterValues() qestion.

peter cooke
Ranch Hand

Joined: Mar 16, 2004
Posts: 317
Suppose I call a servlet and pass in sevaral parameters with the same name but different values.

In relation to request input parameters; How should the String[] returned by getParameters values organized?

The api does not state that the first parameter value in the request is guarenteed to be the first string in the String array returned by getParameterValues(). If I deploy my app on various servers, could I get different ordering of Strings returned by getParameterValues?

CIAO Peter M. Cooke
Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 63202

Yes, the order is arbitrary.

[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
I agree. Here's the link:
subject: getParameterValues() qestion.
It's not a secret anymore!