Цитата(garbuz @ 19.12.2008, 22:57 ) | | Однако значение этого параметра приходит равное null. Почему? |
http://www.w3.org/TR/html401/interact/forms.html#h-17.13 Цитата из спецификации сервлетов:| Цитата | SRV.3.1.1 When Parameters Are Available
The following are the conditions that must be met before post form data will be populated to the parameter set: 1. The request is an HTTP or HTTPS request. 2. The HTTP method is POST. 3. The content type is application/x-www-form-urlencoded. 4. The servlet has made an initial call of any of the getParameter family of methods on the request object.
If the conditions are not met and the post form data is not included in the parameter set, the post data must still be available to the servlet via the request object’s input stream. If the conditions are met, post form data will no longer be available for reading directly from the request object’s input stream.
|
Вкратце суть в том, что браузер при отправке формы с файлом(ами), ставит Content-Type: multipart/form-data, и такой запрос контейнер не разбирает в набор параметров.
Цитата(garbuz @ 19.12.2008, 22:57 ) | | Хотелось бы с самого начала проверять этот параметр... |
Проверяйте Content-Type ну и от этого смотрите дальше... |