|
| |
javascript visibility toggle, always starts "visible" instead of "hidden"
View related threads:
(in this forum
| in all forums)
|
Logged in as: Guest
|
|
|
phillipu
Posts: 86 Joined: 12/12/2001 From: Seattle WA USA Status: offline
|
javascript visibility toggle, always starts "visib... - 5/10/2004 15:21:06
Hi all, I am using some javascript to toggle the visibility of a table, the toggle is working fine, my prob is that whenever the page with the toggle loads, it loads my table as "visible", i need the page to load with the table to toggle as "hidden", then the user can click the text link and the table becomes "visible". Here is the javascript code - <script language="JavaScript">
function toggle(target, iNo)
{
obj=document.getElementById(target+String(iNo));
obj.style.display=( (obj.style.display=='none') ? '' : 'none');
}
</script> this code is the onclick for the toggle - <td bgcolor="#F4F4F4" width="540" class="data" onClick="toggle('status',1)" id="rfcpe_status" style="cursor:hand"> this code is the table that is toggled - <table width="700" border="0" cellspacing="2" cellpadding="2" bgcolor="#FFFFFF" id="status1"> Thanks, Phillip
|
|
New Messages |
No New Messages |
Hot Topic w/ New Messages |
Hot Topic w/o New Messages |
Locked w/ New Messages |
Locked w/o New Messages |
|
Post New Thread
Reply to Message
Post New Poll
Submit Vote
Delete My Own Post
Delete My Own Thread
Rate Posts
|
|
|