Click to See Complete Forum and Search --> : Highlighting Problems


Exuro
07-03-2003, 12:22 PM
I've been working on the layout for a website that my friends and I are working on, and I just recently changed the whole thing from tables to style sheets (as I've heard several times is the proper way to do things). Anyway, I noticed today that when I try to highlight any text on any of the pages, it highlights everything on the page below that spot in the code. I have no idea what's causing this to happen, especially since it seems to only happen in IE (I tested it in Opera and Mozilla and the highlighting worked normally). I currently have the site posted at http://12.211.26.250/. If anyone can help me solve this problem I'd be very appreciative. Thanks!
-- Exuro

Robert Wellock
07-03-2003, 12:29 PM
It's an M$ IE 6.0 bug with CSS "position absolute" if you were using XHTML you could have added the XML declaration and the bug would have been hidden.

Exuro
07-03-2003, 03:11 PM
Does that mean I can't fix it while keeping my current layout?

Robert Wellock
07-04-2003, 08:19 AM
Either convert to XHTML, or use an alternative method of CSS positioning.

Converting to XHTML being one of the more easy options.

richiebman
11-03-2004, 05:46 AM
I know this thread is very old, but I'm currently having this highlighting problem with my sites and curious about what Robert Wellock means when he says

if you were using XHTML you could have added the XML declaration and the bug would have been hidden.

Anyone?

Stephen Philbin
11-03-2004, 06:13 AM
I'm assuming he's saying that throwing IE into quirks mode will remedy the problem.

If throwing IE into quirks fixes it then I suppose you could just stick <!-- --> on a line before the DTD. That would probably put IE in quirks and leave all the other sensible browsers to just ignore it.

I should imagine though that throwing IE into quirks will cause far more problems than it will fix.

So to answer your question richie, using XHTML means you can put an XML declaration ( <?xml version="1.0" encoding="utf-8"?> ) before the DTD. Because IE does not understand what a DTD is it has only two modes of display:

1) Bad

and

2) Very bad

Bad is what some people laughingly call IE's "standards mode". It enters this display mode if the first 10 characters it finds in the document are "<!doctype ".

If it finds anything else, it enters the very bad mode (or "Quirks mode" ), where it will invariably make an abhorrant mess of standard code (but I'm assuming not do the text highlighting glitch).

richiebman
11-03-2004, 08:25 AM
Hmmm.....not sure if I want to make IE even worse than it is already.

However, what is the actual problem? Some completely valid sites I come across are OK and some are not. Can anyone pin down the precise piece of code (or method of writing code) so I can avoid doing what I'm doing for the future?

Apart from my site below, this other site (which is also valid to XHTML 1.1)
the other site (http://www.thesession.org/discussions/display.php/3042)
has the same problem. Could it also perhaps be my OS (I'm on XP Pro). It is of course made by MS so I suppose any ridiculous problem is possible! :mad:

Many thanks,
R

Fang
11-03-2004, 08:56 AM
richiebman it's position:absolute; in .page

richiebman
11-03-2004, 09:50 AM
How pathetic.

I don't have to stop using position:absolute; because of IE 6.0 do I? It's quite useful. Or is it frowned upon to not allow users to highlight text? Maybe as an accessibility issue?

Cheers Fang. At least now I know.

R