View Full Version : please help!
darksidepuffin
01-06-2001, 03:22 PM
Hi I am about to start a new site and I need to know if there is a way to remove table cells,layers and/or images by clicking something?please help I will be internally grateful
Sincerly,
William Crooks
-----------------------------------------
Aim:Williamoose
Icq#98751262
Yahoo:william_cat_warrior
msn:dropalinetowilliam@hotmail.com
Jason
01-07-2001, 09:03 AM
I'm not quite sure what you mean by this. Are you using a WYSIWYG editor or a text editor? If you are using a text editor you delete table cells by removing:
<td></td>
To remove layers get rid of:
<layer></layer>
and to remove images get rid of:
<img src=image.gif>
P.S.
FYI - The correct wording is eternally grateful, not internally :D. (You'd be grateful forever, your insides are not grateful).
------------------
Jason M. DesRoches
Co-Founder / Business Development
Big Resources Network (http://www.bigresources.com)
jason@bigresources.com
ICQ: 17947522
darksidepuffin
01-07-2001, 01:39 PM
hi Jason I am sorry I didn't explain very good :=Þ what I ment is to allow visitors to close them(I am tring to develop a navigation system that can be closed by the visitor)
ps.LOL
------------------
-_=+William Crooks+=_-
[This message has been edited by willamoose (edited 01-07-2001).]
kdjoergensen
01-07-2001, 06:20 PM
In newer browsers (ie5/ns6) you can use the style object's display property to toggle visibilty of individual objects.
example:
<img style="display: inline" src="img1.gif" onclick="this.style.display = 'none'">
<table onclick="this.style.display = 'none'">
<tr>
<td>
Hi
</td>
</tr>
</table>
darksidepuffin
01-07-2001, 06:22 PM
thanks for your help :=] but could the image be used to close the table?
------------------
-_=+William Crooks+=_-
kdjoergensen
01-07-2001, 10:10 PM
If that is all you want, then here is a more universal example which also works on netscape4:
<a href="javascript: hideShow('mytable')"><img border=0 name="myimage" src="...."></a>
<layer id='mytableNS'>
<table id="mytable">
...
...
</table>
</layer>
Following javascript function should go in the head of the document:
<script language="javascript1.2">
<!--
var isOff = false;
function hideShow(elm){
var obj;
if (document.layers) {
obj = document.layers[elm+"NS"];
} else if (document.getElementById) {
obj = document.getElementById(elm).style;
} else if (document.all) {
obj = document.all[elm].style;
} else {
alert('wont work in this browser');
return;
}
if (isOff) {
obj.visibility = 'visible';
isOff = false;
}else {
obj.visibility = 'hidden';
isOff = true;
}
}
//-->
</script>
[This message has been edited by kdjoergensen (edited 01-07-2001).]
darksidepuffin
01-08-2001, 08:49 PM
thanks a bunch I owe ya.:=]
------------------
-_=+William Crooks+=_-
vBulletin® v3.6.7, Copyright ©2000-2009, Jelsoft Enterprises Ltd.