Jump to content

[SOLVED] javascript/Iframe issues


efficacious

Recommended Posts

Hello everyone,

 

I'm currently using JS to create a "popup" window.. which is actully just a div that is positioned absolutley on the page..

 

The problem I'm having is that once the pop up occurs I trigger another JS function to write out an Iframe into the div.. but instead of just writing the Iframe rewrites the whole page to JUST be an Iframe...

 

heres the code i'm using:

<script type="text/javascript">
function ClearDay()
{
document.getElementById('Popper').style.visibility='hidden';
}

function openday(x)
{
document.getElementById("Popper").style.visibility="visible";
ThePage(x);
alert(x);
}
</script>

</head>
<body>
<table id='Popper' onclick='ClearDay();'>
<tr>
	<td>
		<div id='PopDay'>
			<script type="text/javascript">
			function ThePage(z)
			{
			document.write("<iframe src='checkday.php");
			document.write("?id="+z+"'"); 
			document.write("width='500px' height='500px'></iframe>");
			}
			</script>
		</div>
	</td>
</tr>	
</table>

 

thanks for the help everyone,

eff

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.