Has anyone had this problem ???
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   John_Cullen
Posted On:   Monday, June 30, 2003 12:42 AM

I'm fairly new to Struts but have worked on J2EE projects Something really weird is happening on my logon page When I include a reference to a style sheet or an image the page seems to be loaded an extra time I can see this from the JBoss debug window..... As well as the page reloading it totally screws up the posting of the form Instead of posting forward it opens the style sheet in my default editor The weird thing is that when I remove these references from the logon page and log in successfully every other page on the site does not have this problem...... Please help John    More>>

I'm fairly new to Struts but have worked on J2EE projects

Something really weird is happening on my logon page

When I include a reference to a style sheet or an image the page seems to be loaded an extra time

I can see this from the JBoss debug window.....

As well as the page reloading it totally screws up the posting of the form

Instead of posting forward it opens the style sheet in my default editor



The weird thing is that when I remove these references from the logon page and log in successfully every other page on the site does not have this problem......



Please help



John

   <<Less

Re: Has anyone had this problem ???

Posted By:   Stratos_Nikolaidis  
Posted On:   Monday, June 30, 2003 06:34 AM

Check in your web.xml, security configuration section, NOT to include the directory where your stylesheet exists.



For example:




MyApp
/application/*
/mainpages/*



If you include for example the directory where your stylesheet exists too ( let's say /styles/*) the following will happen:



A user calls your login page. Trying to call the style (which is in a secure area) will call your login page (for accessing the stylesheet file - of course not using it - don't forget it's not yet loaded) and after a successful login, it shows the file you asked to load - aka your stylesheet file!



Of course, out of the secure area you must have the login/relogin pages (trying to call the login page will cause the system to call the login page. After a successfull login, will continue loading the page you called, aka your login page!!)



--

Stratos Nikolaidis.

Thessaloniki, Greece

About | Sitemap | Contact