smarty-javascript
| From: | (PHPDiscuss - PHP Newsgroups and mailing lists) | Date: | Tue, 16 Mar 2004 19:42:37 +0000 |
| Subject: | smarty-javascript | ||
| Groups: | php.smarty.general | ||
| Request: | Send a blank email to php-smarty-general+get-11132@lists.php.net to get a copy of this message | ||
html file
{* Smarty *}
{literal}
<script language="javascript">
var flag0;
//alert (flag);
var ce_pun="<tr><td class='style23 style40 style42'> MANAGE PRODUCTS
<br>
<br>help</td></tr>";
function vizibilitate()
{
var table=document.getElementById('help');
if (document.hide_form.help_button.value=="Show")
{
if (!flag==0)
{
if(table.innerHTML!="")
{
table.innerHTML="";
}
else
{
table.innerHTML=ce_pun;
}
document.hide_form.help_button.value="Hide";
}//if flag
else
{
table.innerHTML=ce_pun;
flag=1;
document.hide_form.help_button.value="Hide";
}
}//if
else
{
document.hide_form.help_button.value="Show";
table.innerHTML="";
flag=1;
}
}
</script>
{/literal}
<td valign="bottom">
<form name="hide_form">
<input type="button" name="help" value="Help!"
onClick="javaScript:vizibilitate()">
<input type="hidden" name="help_button" value="Show">
</form>
</td>
<table id="help" width="80%" border="1" cellpadding="6"
cellspacing="0"
bordercolor="#009900" bgcolor="#FFFFCC">
</table>
-----This works with Mozzila but it doesn't work with InternetExplorer.
Somebody know why? Please help me!