struts-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alexey <forum-struts-...@opensymphony.com>
Subject Little problem with filter paramssetter
Date Mon, 14 May 2007 07:06:17 GMT
In JVM setted locale ru_RU. Decimal separator `comma` (,). Struts 2.0.6, Tomcat 5.5.17, JBoss
4.0.4 GA with EJB 3 

Code:
System.out.println("TIME: " + ServletActionContext.getRequest().getParameter("timeWork").getClass());
System.out.println("TIME: " + ServletActionContext.getRequest().getParameter("timeWork"));
... then ...
System.out.println("TIME: " + ServletActionContext.getRequest().getAttribute("timeWork").getClass());
System.out.println("TIME: " + ServletActionContext.getRequest().getAttribute("timeWork"));

When i post form on server in different browsers occurs next.
IE:
14:21:25,890 INFO [STDOUT] TIME: class java.lang.String
14:21:25,890 INFO [STDOUT] TIME: 2,5
...
14:21:25,906 INFO [STDOUT] TIME: class java.lang.Double
14:21:25,906 INFO [STDOUT] TIME: 2.5

FF:
14:32:31,750 INFO [STDOUT] TIME: class java.lang.String
14:32:31,750 INFO [STDOUT] TIME: 2,5
...
14:21:25,906 INFO [STDOUT] TIME: class java.lang.Double
14:21:25,906 INFO [STDOUT] TIME: 25

Other if I type 2,5 whith dot (2.5):
IE:
14:21:25,890 INFO [STDOUT] TIME: class java.lang.String
14:21:25,890 INFO [STDOUT] TIME: 2.5
...
14:21:25,906 INFO [STDOUT] TIME: class java.lang.Double
14:21:25,906 INFO [STDOUT] TIME: null

FF:
14:32:31,750 INFO [STDOUT] TIME: class java.lang.String
14:32:31,750 INFO [STDOUT] TIME: 2.5
...
14:21:25,906 INFO [STDOUT] TIME: class java.lang.Double
14:21:25,906 INFO [STDOUT] TIME: 2.5

Can you say why params so different in different browsers?
---------------------------------------------------------------------
Posted via Jive Forums
http://forums.opensymphony.com/thread.jspa?threadID=83515&messageID=149483#149483


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Mime
View raw message