This week's book / license giveaways are in the JDBC and Relational Databases and Java in General forums.
We're giving away four copies each of PostGIS in Action and Java Advanced Topics Training and have the authors on-line!
See this thread and this one for details.
The moose likes Servlets and the fly likes calling a servlet before each html page request Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Java » Servlets
Bookmark "calling a servlet before each html page request" Watch "calling a servlet before each html page request" New topic
Author

calling a servlet before each html page request

davy nolan
Greenhorn

Joined: Mar 20, 2001
Posts: 6
Hi,
Is it possible to have a servlet execute everytime a http request is made to the server, even if the request is for a html page.
Also if I have relative links in my html pages will the servlet still be able to obtain the complete directory structure from '/docs' down i.e. '/top/sub/subIndex.html' even if the user just requests 'subIndex.html'.
Many thanks,
Davy
Anonymous
Ranch Hand

Joined: Nov 22, 2008
Posts: 18944
Hi Davy,
To answer the first part... I believe it is possible, but sometimes it's overkill. Secondly, I think the relative links part should be okay.
Cheers,
Scott
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: calling a servlet before each html page request