dojoX
dojoX

Reputation: 1615

user friendly urls in j2ee application

I want to develop a forum application using jsp, servlets.Now i want to have user friendly url to each post eg

http://stackoverflow.com/questions/5509365/associating-a-dojoattachpoint-to-a-div-create-dynamicallycaly

and I dont want to use something like that

 http://stackoverflow.com/post=1234

How can i have such user friendly urls.

Upvotes: 1

Views: 1712

Answers (2)

stacker
stacker

Reputation: 68942

I guess you are looking for Representational State Transfer (REST)

Upvotes: 2

James.Xu
James.Xu

Reputation: 8295

you need to use a technology named URL Rewrite, usually people put a nginx in front of tomcat, so the nginx get the request:

http://stackoverflow.com/questions/5509365/associating-a-dojoattachpoint-to-a-div-create-dynamicallycaly`

and nginx forward a url to tomcat which tomcat can understand:

http://stackoverflow.com/questions?id=5509365


or if you want pure java solution, then take a look at:

http://code.google.com/p/urlrewritefilter/

Upvotes: 0

Related Questions