HighDots Forums  

Back button interferes with navigation - how can this be avoided?

Cascading Style Sheets Layout/presentation on the WWW (comp.infosystems.www.authoring.stylesheets)


Discuss Back button interferes with navigation - how can this be avoided? in the Cascading Style Sheets forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
chri_schiller@yahoo.com
 
Posts: n/a

Default Back button interferes with navigation - how can this be avoided? - 04-09-2005 , 05:36 PM






My webpage with a free textbook has a simple html navigation.
Moving the cursor on the menu item makes
appear the menu item red, using onmouseover.

If I click that menu item, I get to the new page.
Everything works fine. But if I then bo back
with the back button (Mac Safari and IE - have not
checke on PC yet) I do get back to the previous
page, but with the choice of the next already/still highlighted.
(There are two red bars in this case.) Ugly.

All the programming is in html pages and in one css file;
nothing is hidden. (See http://www.motionmountain.net )
What is going wrong? How can one avoid this?

Any hint is appreciated.

Regards

Christoph Schiller


Reply With Quote
  #2  
Old   
Barbara de Zoete
 
Posts: n/a

Default Re: Back button interferes with navigation - how can this be avoided? - 04-09-2005 , 05:43 PM






On 9 Apr 2005 14:36:28 -0700, <chri_schiller (AT) yahoo (DOT) com> wrote:

Quote:
My webpage with a free textbook has a simple html navigation.
Moving the cursor on the menu item makes
appear the menu item red, using onmouseover.

If I click that menu item, I get to the new page.
Everything works fine. But if I then bo back
with the back button (Mac Safari and IE - have not
checke on PC yet) I do get back to the previous
page, but with the choice of the next already/still highlighted.
(There are two red bars in this case.) Ugly.

All the programming is in html pages and in one css file;
nothing is hidden. (See http://www.motionmountain.net )
What is going wrong? How can one avoid this?

I didn't go look, but it doesn't sound like anything going wrong to me.
The element a probably still has focus. If you style a:focus (or maybe
a:active if it turns out to be active still) with the background color of
choice, your so called problem might just disappear.


--
,-- --<--@ -- PretLetters: 'woest wyf', met vele interesses: ----------.
Quote:
weblog | http://home.wanadoo.nl/b.de.zoete/_private/weblog.html |
webontwerp | http://home.wanadoo.nl/b.de.zoete/html/webontwerp.html |
zweefvliegen | http://home.wanadoo.nl/b.de.zoete/html/vliegen.html |
`-------------------------------------------------- --<--@ ------------'


Reply With Quote
  #3  
Old   
chri_schiller@yahoo.com
 
Posts: n/a

Default Re: Back button interferes with navigation - how can this be avoided? - 04-09-2005 , 06:11 PM




What is focus? I have never used the term in my stylesheet.


Reply With Quote
  #4  
Old   
Barbara de Zoete
 
Posts: n/a

Default Re: Back button interferes with navigation - how can this be avoided? - 04-09-2005 , 06:16 PM



On 9 Apr 2005 15:11:22 -0700, <chri_schiller (AT) yahoo (DOT) com> wrote:

[Please learn to quote properly. Quote the bit you reply to, attribute it
and then reply underneath the quote.

Quote:
What is focus? I have never used the term in my stylesheet.

<http://www.w3.org/TR/CSS2/selector.html#dynamic-pseudo-classes>

--
,-- --<--@ -- PretLetters: 'woest wyf', met vele interesses: ----------.
Quote:
weblog | http://home.wanadoo.nl/b.de.zoete/_private/weblog.html |
webontwerp | http://home.wanadoo.nl/b.de.zoete/html/webontwerp.html |
zweefvliegen | http://home.wanadoo.nl/b.de.zoete/html/vliegen.html |
`-------------------------------------------------- --<--@ ------------'


Reply With Quote
  #5  
Old   
Tony Marston
 
Posts: n/a

Default Re: Back button interferes with navigation - how can this be avoided? - 04-10-2005 , 05:45 AM




<chri_schiller (AT) yahoo (DOT) com> wrote

Quote:
My webpage with a free textbook has a simple html navigation.
Moving the cursor on the menu item makes
appear the menu item red, using onmouseover.

If I click that menu item, I get to the new page.
Everything works fine. But if I then bo back
with the back button (Mac Safari and IE - have not
checke on PC yet) I do get back to the previous
page, but with the choice of the next already/still highlighted.
(There are two red bars in this case.) Ugly.
This is due to the browser settings on the client, which you cannot
override. By using the back button to return to a page that page will be
shown as it was (i.e. with the forward navigation links still marked as
unselected) unless the browser is specifically told to reload the page. It
is only by reloading the page will the status of any links be evaluated.

--
Tony Marston

http://www.tonymarston.net



Quote:
All the programming is in html pages and in one css file;
nothing is hidden. (See http://www.motionmountain.net )
What is going wrong? How can one avoid this?

Any hint is appreciated.

Regards

Christoph Schiller




Reply With Quote
  #6  
Old   
Harlan Messinger
 
Posts: n/a

Default Re: Back button interferes with navigation - how can this be avoided? - 04-11-2005 , 10:39 AM



chri_schiller (AT) yahoo (DOT) com wrote:
Quote:
My webpage with a free textbook has a simple html navigation.
Moving the cursor on the menu item makes
appear the menu item red, using onmouseover.

If I click that menu item, I get to the new page.
Everything works fine. But if I then bo back
with the back button (Mac Safari and IE - have not
checke on PC yet) I do get back to the previous
page, but with the choice of the next already/still highlighted.
(There are two red bars in this case.) Ugly.
Ugly? It reminds the user that he's already visited the page to which
the link leads. That's useful, and it's been normal browser presentation
since the beginning of graphical browsers. Why is that a problem?


Reply With Quote
  #7  
Old   
Pierre Goiffon
 
Posts: n/a

Default Re: Back button interferes with navigation - how can this be avoided? - 04-12-2005 , 04:20 AM



Harlan Messinger wrote:
Quote:
Ugly? It reminds the user that he's already visited the page to which
the link leads. That's useful, and it's been normal browser presentation
since the beginning of graphical browsers.
And it has always been a problem for web application developpers since
the very beginning of web developpment.
In web application, it could be very difficult to manage a click on a
back button - because you're lossing the user context when he does that.


Reply With Quote
  #8  
Old   
Christoph Schiller
 
Posts: n/a

Default Re: Back button interferes with navigation - how can this be avoided? - 04-15-2005 , 07:49 AM



Greg Schmidt <gregs (AT) trawna (DOT) com> wrote

Quote:
On 10 Apr 2005 00:08:03 -0700, chri_schiller (AT) yahoo (DOT) com wrote:
tr
td class="lmenu" onmouseover="this.className='lmon'"
onmouseout="this.className='lmout'"
onClick="window.self.location='text.html'"><a
href="text.html">Download</a></td
/tr
...
Anyway, when clicking on "back" the previous choise is still there,
as if the pointer had remained over it - which it is not; the pointer
is on the back button. Why?

Seems that it's because there was never an "onmouseout" event generated.
Maybe your onClick should call a function which does the onmouseout code
and then loads the new page? (That's a wild guess, I haven't tried it.)
Even better, why not get rid of all the JavaScript junk that won't work
for a large percentage of the population anyway and do this all with the
CSS a: pseudoclasses?
Would you let me know how to do it?

Regards

Christoph Schiller


Reply With Quote
  #9  
Old   
Greg Schmidt
 
Posts: n/a

Default Re: Back button interferes with navigation - how can this be avoided? - 04-15-2005 , 12:04 PM



On 15 Apr 2005 04:49:50 -0700, Christoph Schiller wrote:

Quote:
Greg Schmidt <gregs (AT) trawna (DOT) com> wrote

On 10 Apr 2005 00:08:03 -0700, chri_schiller (AT) yahoo (DOT) com wrote:
tr
td class="lmenu" onmouseover="this.className='lmon'"
onmouseout="this.className='lmout'"
onClick="window.self.location='text.html'"><a
href="text.html">Download</a></td
/tr
...
Anyway, when clicking on "back" the previous choise is still there,
as if the pointer had remained over it - which it is not; the pointer
is on the back button. Why?

Seems that it's because there was never an "onmouseout" event generated.
Maybe your onClick should call a function which does the onmouseout code
and then loads the new page? (That's a wild guess, I haven't tried it.)
Even better, why not get rid of all the JavaScript junk that won't work
for a large percentage of the population anyway and do this all with the
CSS a: pseudoclasses?

Would you let me know how to do it?
I think you're looking for something like http://trawna.com/cssmenu.html
It should work at least as well, probably better, and it's a fraction of
the code. Enjoy!

--
Greg Schmidt gregs (AT) trawna (DOT) com
Trawna Publications http://www.trawna.com/


Reply With Quote
  #10  
Old   
Greg Schmidt
 
Posts: n/a

Default Re: Back button interferes with navigation - how can this be avoided? - 04-15-2005 , 12:58 PM



On Fri, 15 Apr 2005 12:04:43 -0400, Greg Schmidt wrote:

Quote:
I think you're looking for something like http://trawna.com/cssmenu.html
Damn! That should have been http://trawna.com/test/cssmenu.html
(Repeat to self: copy-and-paste, copy-and-paste)
Tested on Opera 6/7, Netscape 6, Firefox and IE5/6. Less than stellar
on NS4 and IE4, but their combined market share should be less than the
percentage of users without JavaScript (either through personal or
institutional choice), and CSS hiding tricks can be done to improve the
look for them if desired.

--
Greg Schmidt gregs (AT) trawna (DOT) com
Trawna Publications http://www.trawna.com/


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.