mardi 26 mai 2015

Sub-Domains using struts2 framework

I need to write a feature in my application like this .Suppose my website is named mysite.com ,when a request like mysite.com/tulip is made the context root changes to tulip.mysite.com for the entire session. Tulip is the name of the estore of one of my registered users. So the URL is typed in by my user or the client of my user's estore. I am in very urgent need to implement this feature in struts2 . Any help will be highly appeciated. Have read certain posts regarding creation of virtual hosts in server.xml file in apache but they donot seem to have that dynamicity. I also want to know if this feature can be implemented using only code or should the solution also need server and DNS configuration. Whether simpler techniques like response redirection or request forwording or URL rewriting can solve the problem. Please Help.




Aucun commentaire:

Enregistrer un commentaire