![]() |
|
|
+ Search |
![]()
|
Apr 6th, 2008 18:38
ha mo, Colin Fraser, Weijun Zhang,
Try
function swapLayer(layer1name, layer2name) {
if (navigator.appName=="Netscape") {
layer1name.visibility ="hide";
layer2name.visibility="visible";
}
else {
if (navigator.appName=="Microsoft Internet Explorer"){
layer1name.visibility = "hidden"
layer2name.visibility="visible"; }
}
}
<div id="imagelayer" style="{visibility:visible;}">
<img src="myImage.gif onClick=swapLayer("imageLayer, textLayer")>
>
</div>
<div id="textLayer" style="{visibility:hidden;}>
<a href="javascript:void()" onClick=swapLayer("textLayer, imageLayer")
Collapsible text</a>
</div>
Of course, the major problem comes from the fact that there are more
than two browsers out there, so what happens if someone is using a
browsert hat is nioether N or IE?
http://www.businessian.com
http://www.computerstan.com
http://www.financestan.com
http://www.healthstan.com
http://www.internetstan.com
http://www.moneyenews.com
http://www.technologystan.com
http://www.zobab.com
http://www.healthinhealth.com