Javascript show hide and change attribute value on click
<script type="text/javascript">
function uploadform()
{
var f1=document.getElementById("frm");
var b1=document.getElementById("btn");
if(f1.style.display=="none")
{
f1.style.display="block";
b1.setAttribute("value","Hide");
}
else
{
f1.style.display="none";
b1.setAttribute("value","Upload");
}
}
</script>
<script type="text/javascript">
function uploadform()
{
var f1=document.getElementById("frm");
var b1=document.getElementById("btn");
if(f1.style.display=="none")
{
f1.style.display="block";
b1.setAttribute("value","Hide");
}
else
{
f1.style.display="none";
b1.setAttribute("value","Upload");
}
}
</script>
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.