balanca
12 May 2008, 11:27 AM
Hello,
I have a problem with Javascript. I am trying to show a hidden iFrame when user submits form. I am new in php and javascript .....please help
here is the code
javascript in head section of html
<script type="text/javascript">
<!--
function hideMe(){
// Hide or show iframe
if(document.getElementById("myframe").style.visibility=="visible"){
document.getElementById("myframe").style.visibility="hidden"
}
else{
document.getElementById("myframe").style.visibility="visible"
}
//-->
</script>
body
<input name="shrani" type="submit" id="shrani" value="Shrani" onclick="hideMe()"/>
<iframe id="myframe" width="100%" src="vnosPozicija.php" style="visibility:hidden"></iframe>
I have a problem with Javascript. I am trying to show a hidden iFrame when user submits form. I am new in php and javascript .....please help
here is the code
javascript in head section of html
<script type="text/javascript">
<!--
function hideMe(){
// Hide or show iframe
if(document.getElementById("myframe").style.visibility=="visible"){
document.getElementById("myframe").style.visibility="hidden"
}
else{
document.getElementById("myframe").style.visibility="visible"
}
//-->
</script>
body
<input name="shrani" type="submit" id="shrani" value="Shrani" onclick="hideMe()"/>
<iframe id="myframe" width="100%" src="vnosPozicija.php" style="visibility:hidden"></iframe>