Sent by George Smyth on 25 January 2005 21:09
Gulp - never mind, found the problem. <<blush>>
Thganks again -
george
-----Original Message-----
From: [EMAIL-REMOVED]
[EMAIL-REMOVED]] On Behalf Of George Smyth
Sent: Tuesday, January 25, 2005 4:06 PM
To: [EMAIL-REMOVED]
Subject: RE: [css-d] Validation Blues
Jens -
I changed my code to:
<!--[if IE]>
<li><a href='#' title='Increase the visual size of the
website.'>
<span onclick='GoMagnify(\"Up\")'>
Magnify Page</span></a>
<a href='#' title='Set visual size of the website to
normal.'>
<span onclick='GoMagnify(\"Normal\")'>
Normal View</span></a></li>
<![endif]-->
Unfortunately, this does not appear to work. IE on a Windows 2000
computer sows it as a syntax error, and IE on a Windows XP computer
simply does not display the list item.
If I use the following code:
<!--[if IE]>
<li>this is a test</li>
<![endif]-->
it is also not listed.
Am I doing something wrong here?
Cheers -
george
-----Original Message-----
From: [EMAIL-REMOVED]
[EMAIL-REMOVED]] On Behalf Of Jens
Brueckmann
Sent: Tuesday, January 25, 2005 3:07 PM
To: [EMAIL-REMOVED]
Subject: Re: [css-d] Validation Blues
On Tue, 25 Jan 2005 12:38:43 -0500, George Smyth [EMAIL-REMOVED]>
wrote:
> I normally stay away from anything that is browser-specific, but one
> exception has been the ability to magnify the page, which has shown
> itself to be useful to some of our low-vision users. This uses the
zoom
> property only available in IE (hopefully others will embrace this).
When zooming pages in Opera, every element - images included - is
resized.
> I have this option at the bottom of the main navigation, which is
listed
> within <ul> tags (the code can be seen at http://usna.com). Because I
> do not want to offer this to browsers that cannot utilize it, I am
using
> JavaScript to detect the browser - if it is IE then JavaScript
displays
> the option.
>
> The validator is properly (I am sure) telling me that my JavaScript
code
> should not be within the <ul> tags, but I do not know of another way
of
> doing this.
as you would like the list element only to be displayed in Internet
Explorer it would be best, if you wrapped the HTML inside conditional
comments instead of using navigator.appName for browser detection (which
is, by the way, the worst method for browser detection) and
document.write() :
<!--[if IE]>
<li>
content
</li>
<![endif]-->
Though being off-topic I would also like to draw your attention to the
fact, that document.write() would not work for proper XHTML documents
served as application/xhtml+xml. You should use DOM methods instead. And
last not least any event-handler should be in lowercase when using
XHTML.
Hope this helps.
Cheers,
jens
--
Jens Brueckmann
http://www.j-a-b.net/
______________________________________________________________________
css-discuss [EMAIL-REMOVED]]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/
______________________________________________________________________
css-discuss [EMAIL-REMOVED]]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/
______________________________________________________________________
css-discuss [EMAIL-REMOVED]]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/