Faxsy Faxsy - 1 year ago 76
PHP Question

Iframe form should open new page

I have a login box showed as iframe

<div id="auth-container" >
<iframe src="loginiframe.php" width="100%" height="100%" frameBorder="0">Browser not compatible.</iframe>

Now inside the loginiframe.php there is a form submit

<form action="auth.php">

where I process my request , and I would like to redirect to another page after process but now

When submit is clicked the auth.php it process the request and redirect to next page but showed in the iframe

I would like to redirect them to account.php page

daf daf
Answer Source

Your auth.php page could redirect to another page with the following script block:

<script type="text/javascript">
window.parent.location = 'home.php';

assuming that you're redirecting to "home.php" after authentication.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download