Home Articles FAQs XREF Games Software Instant Books About Feedback Search Site-Map
irt.org logo

Q497 How can I show an image but only in browsers that don't support or have javascript disabled?

irt.org | Knowledge Base | JavaScript | Image | Q497 [ previous next ]

Q497 How can I show an image but only in browsers that don't support or have javascript disabled?

Either use the <NOSCRIPT> tag:

<noscript>
<img src="picture.gif" width="100" height="100">
</noscript>

Or use JavaScript to stop it being shown:

<img src="picture.gif" name="myImage" width="100" height="100">

<script language="JavaScript"><!--
if (document.images) {
    document.images['myImage'].src = 'blank.gif';
}
//--></script>

Although this last method only works on browsers that support the image object - which excludes Netscape Navigator 2 and Internet Explorer 3.


Provide feedback ...
AddThis Social Bookmark Button

Provide feedback ... AddThis Social Bookmark Button


Last Updated: 30th March 2008. Maintained by: Martin Webb and Michel Plungjan
irt.org liability, trademark, document use, privacy statement and software licensing rules apply.
Copyright © 1996-2008 irt.org, All Rights Reserved.