Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Knute Snortum
  • Bear Bibeault
Saloon Keepers:
  • Ron McLeod
  • Tim Moores
  • Stephan van Hulst
  • Piet Souris
  • Ganesh Patekar
Bartenders:
  • Frits Walraven
  • Carey Brown
  • Tim Holloway

URL Rewriting in Struts Application

 
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How to Change url of my application ,i have url like http://localhost:8001/Kinara/login.do?method=loginPage ....i have to change this url to any short form ......

How to do this any body help me.........

Thanks In Advance,
SivaReddy
 
Greenhorn
Posts: 2
Eclipse IDE Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can use the following tags that are available on web.xml



 
Siva Reddya
Greenhorn
Posts: 12
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Siva Reddya wrote:How to Change url of my application ,i have url like http://localhost:8001/Kinara/login.do?method=loginPage ....i have to change this url to any short form ......like anyname/login/.....

How to do this any body help me.........

Thanks In Advance,
SivaReddy

 
Siva Reddya
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
<welcome-file-list>
<welcome-file>login.jsp</welcome-file>
</welcome-file-list>

is used to execute any default pages like jsp , html .....in my case i have to change every url for that we can use urlrewritefilter concept ,but i don't know how to use <rule> in urlrewrite.xml for struts application if any body knows please tell me.

i am using this below rule in urlrewrite.xml, but it is not rewrite the url........

<urlrewrite>
<rule>

<from>/login.do?method=([a-zA-Z]+)$</from>
<to type="redirect">/Bricks2Home/$1</to>
</rule>
</urlrewrite>

Thanks In Advance,
SivaReddy
 
Consider Paul's rocket mass heater.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!