Refresh problem

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi

I am using IE 6 to browse a site that I am developing. The first
page of the site is a frameset as follows:

<FRAMESET rows="50,*" border="0">
<FRAME name="topframe" id="topframe" src="./Head.html" marginwidth="0"
marginheight="0" frameborder=0 scrolling="no">
<FRAME name="left" src="Login/loginscreen.jsp" marginwidth="0"
marginheight="0"
frameborder=0>

</FRAMESET>


So the first screen is loginscreen.jsp which shows a login page.

After I login, the bottom frame called "left" is replaced by another
frameset page:


<FRAMESET rows="19,*" border="0">
<FRAME name="mnuframe" src="./menubar.jsp" marginwidth=0
" marginheight="0" frameborder=0 scrolling="no">
<FRAME name="mainFrame" src="Landing/index.jsp" marginwidth="0"
marginheight="0"
frameborder="0">

</FRAMESET>

Now when I click on the refresh button in the toolbar, IE shows the
original page (within the login page) effectively logging me out,
whereas the expected behaviour would be to stay at the same
page.

Any ideas will be appreciated.

Thanks,

Debnath
 
debnath wrote on Wed, 10 Jan 2007 23:21:00 -0800:
Now when I click on the refresh button in the toolbar, IE shows the
original page (within the login page) effectively logging me out,
whereas the expected behaviour would be to stay at the same
page.

The frameset never changes the initial URL for the login page, so when you
click refresh IE is refreshing the entire frame set - which is correct. You
can refresh individual frames by right clicking inside them and choosing
Refresh from the popup menu.

A much better solution would be to recode the login system to use the same
URL and having the login details posted back. That way if the user is not
logged in the frame shows the login form, and if they are logged in it shows
whatever they would normally see there - and if they click the Refresh
button, it doesn't show the login form because the session handling code
shows the correct content rather than the login form.

Another solution would be have the loginscreen code check to see if the user
is logged, and if so redirect to the correct content page.

This is another good reason to try and avoid frames - they really make a
mess of the use of the Refresh button.

Dan
 
Thanks for your reply.

IMO, a refresh from the toolbar should repaint each page within each frame.
If there is a frame containing a frame, then it should recursively repaint the
pages.

Now does IE know what is the URL of each page ? The answer is
yes because when I right click on each page and look up the
Properties option, it shows the page's URL.

So IE has the information to repaint the pages. But it is not doing that.
So my question is what exactly does a refresh do ? What is the definition
of a refresh ?

Incidentally, I would like to add that if the first page (containing the
frameset) is a jsp, then a refresh from the second page ("after-login page")
shows the first page. However, if the first page is an html, then a
refresh from the second page shows the second page.

Note that I am using Struts, so I don't know if it is adding to the
problems.

Thanks,
Debnath
 
debnath wrote on Thu, 11 Jan 2007 23:46:00 -0800:
Thanks for your reply.

IMO, a refresh from the toolbar should repaint each page within each
frame. If there is a frame containing a frame, then it should recursively
repaint the pages.

Now does IE know what is the URL of each page ? The answer is
yes because when I right click on each page and look up the
Properties option, it shows the page's URL.

So IE has the information to repaint the pages. But it is not doing that.
So my question is what exactly does a refresh do ? What is the definition
of a refresh ?

The refresh button refreshes the URL in the address bar. So IE grabs that
page again which has the original frameset, which points at the login page.
Incidentally, I would like to add that if the first page (containing the
frameset) is a jsp, then a refresh from the second page ("after-login
page") shows the first page. However, if the first page is an html, then a
refresh from the second page shows the second page.

Note that I am using Struts, so I don't know if it is adding to the
problems.

I have no experience of jsp or Struts, but I have plenty of ASP experience.
I've just tested here with a frameset that includes ASP pages, and
refreshing individual frames works fine. I can only guess that your "after
login" page does a redirect to the "login" page if it's refreshed, possibly
due to some sort of session variable being reset.

Dan
 
Back
Top