...

View Full Version : Hide From IE



uncrocks
08-13-2008, 04:15 PM
I have the following code....

<div class="scroll">
<A href="mailto:****@aim.com?subject='Hi'">E-mail Me</A>
<br><a href="aim:goIM:" screenname='****'>AIM Message Me</a>
<br><a href="http://www.myspace.com">Myspace</a>
<br><a href="http://www.myspace.com/****">My Myspace</a>
</div>
<style>
.scroll{
width: 200px;
height: 50px;
overflow: auto;
padding: 4px;
border: grey 2px solid;
}
</style>
Is there any way i can hide it from all versions of Internet Explorer?:confused:

rnd me
08-13-2008, 04:31 PM
<!>
[i]<div class="scroll">
<A href="mailto:****@aim.com?subject='Hi'">E-mail Me</A>
<br><a href="aim:goIM:" screenname='****'>AIM Message Me</a>
<br><a href="http://www.myspace.com">Myspace</a>
<br><a href="http://www.myspace.com/****">My Myspace</a>
</div>
<style>
.scroll{
width: 200px;
height: 50px;
overflow: auto;
padding: 4px;
border: grey 2px solid;
}
</style>
<![endif]>



this works just fine, but does prevent validation, if that matters to you (doesn't look like it does).

uncrocks
08-13-2008, 05:16 PM
Internet Explorer is 'IE'...
What is Firefox????:confused:
By the Way Thanks for the First Reply:thumbsup:

abduraooft
08-13-2008, 05:21 PM
See http://www.cssplay.co.uk/menu/conditional.html

<!--[if !IE]><!-->
<h1>You are NOT using Internet Explorer</h1>
<!--<![endif]-->

rnd me
08-13-2008, 06:56 PM
its more complicated to screen for a particular non-ie browser.

one way would be to turn the html into a valid string, and check navigator.userAgent to determine the browser, and if a match is made, document.write the html string to show the code in that browser.

uncrocks
08-15-2008, 08:21 PM
So Something Like This?


if (navigator.userAgent="Firefox") {
document.write(stringwhatever);
}



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum