File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Spring and the fly likes issuer with internationalization Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Frameworks » Spring
Bookmark "issuer with internationalization" Watch "issuer with internationalization" New topic
Author

issuer with internationalization

fabian verbeek
Ranch Hand

Joined: Oct 20, 2012
Posts: 52
Hi,

i'm trying to use internationalization from spring.
i've an index.jsp containing a frame createUser.jsp, it stayes always with the default language. when i try to use this link: user/creationUser?lang=fr
it refreshes the page but the language stay french

my web.xml


my creationUser-context.xml


my controller


thanks for your help
Bill Gorder
Bartender

Joined: Mar 07, 2010
Posts: 1646
    
    7

I would not use the DefaultAnnotationHandlerMapping if you are using the newest Spring I would just remove that all together. You no longer have to register the interceptors on the handler mappings anymore either you can make it applicable for all controllers.




Are your message properties files properly named?

I see you are doing


Why would you expect that to not be french?

[How To Ask Questions][Read before you PM me]
fabian verbeek
Ranch Hand

Joined: Oct 20, 2012
Posts: 52
thanks

How can i make it applicable for all controllers? Where do i pu the lines, you gave?

It's really difficult to find a correct tutorial
Bill Gorder
Bartender

Joined: Mar 07, 2010
Posts: 1646
    
    7

Like I said replace



with




You will need the make sure the mvc namespace is defined in your context xml.
fabian verbeek
Ranch Hand

Joined: Oct 20, 2012
Posts: 52
thanks for your helpful answer.

But how can i do to intercept it for every page? Do i have to put this line in my all context xml or are there a way to make a context for all the application?

thanks
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: issuer with internationalization
 
Similar Threads
Spring annotation no handler found
Spring MVC Request Mapping
no WebApplicationContext found: no ContextLoaderListener registered?
spring internalization not working with spring security
Problem running app under Tomcat v7