aspose file tools
The moose likes Struts and the fly likes Struts 2 + Dynamic Struts.xml ?? Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


JavaRanch » Java Forums » Frameworks » Struts
Reply Bookmark "Struts 2 + Dynamic Struts.xml ??" Watch "Struts 2 + Dynamic Struts.xml ??" New topic
Author

Struts 2 + Dynamic Struts.xml ??

Nishan Patel
Ranch Hand

Joined: Sep 07, 2008
Posts: 676

Hello All,

I am working on Struts 2 and we have functionality like change them by admin change all site according.

For that I have create folder as Theme name at server webapps and make jsp.

Admin update that jsp and make change at front side.

so can any one tell me how to change my struts.xml file only make code at one java class.

for ex:

<action name="aboutUs" class="com.action.FullScreenAction">
<result name="success">${themeFolder}/AboutUs.jsp</result>
</action>

this will effect like :

for theme name "Default"

<action name="aboutUs" class="com.action.FullScreenAction">
<result name="success">/jsp/front/AboutUs.jsp</result>
</action>

for theme Blue

<action name="aboutUs" class="com.action.FullScreenAction">
<result name="success">/jsp/front/blue/AboutUs.jsp</result>
</action>

waiting for your reply.



Thanks, Nishan Patel
SCJP 1.5, SCWCD 1.5, OCPJWSD Java Developer,My Blog
Nishan Patel
Ranch Hand

Joined: Sep 07, 2008
Posts: 676


Hello All,

Please help if any body knows ...........
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: Struts 2 + Dynamic Struts.xml ??
 
Similar Threads
unable to exceute logout program
Autocompleter with ajax theme
Struts 2 checkboxlist error - list key could not be resolved
appfuse validation problem
Struts2-Spring annotation