Hi, I have a login form that is displayed in a left frame that allows a user to login & once logged in to view forum details. The login form has "forgoten password" & "registered" links displayed whilst logged out & forum details links when logged in. They all open up in a frame called "mainframe". This is fine apart from if the user presses "login" before entering any details it displays the "invalid or inactive" screen in the wrong (left or _self) frame. I have tried to figure out where i put target, but for this last problem i can not. Can someone please help. I have enclosed the code & also the url www.gx30.co.uk/Version2/ and press the "login" button to see what i mean.
<!-- USER -->
<table width="100%" cellpadding="0" cellspacing="0" border="0">
<tr>
<td bgcolor="#FF0000"> </td>
<td width="100%" align="center" background="/webimages/newsbg.gif" bgcolor="#FF0000"><span class="cattitle"><font color="#FFFFFF">User
Control</font></span></td>
<td bgcolor="#FF0000"> </td>
</tr>
<tr>
<td colspan="100%">
<?php if ($userdata) { ?>
<table width="100%" border="1" cellpadding="3" cellspacing="0" bordercolor="#FF0000" class="forumline">
<tr>
<td class="row1" align="center" width="100%">
<?php if ($userdata['session_logged_in']) { ?>
<table>
<tr>
<td align="center" valign="top">
<?php if ($userdata['user_avatar_type'] > 0) { ?>
<?php if ($userdata['user_avatar_type'] == 1) { ?>
<?php } elseif ($userdata['user_avatar_type'] > 1) { ?>
<?php } ?>
<?php } else { ?>
<?php } ?>
</td>
</tr>
<tr>
<td valign="top">
<span class="gensmall">
Welcome back <a href="<?php echo $phpbb_root_path; ?>profile.php?mode=viewprofile&u=<?php echo $userdata['user_id']; ?>" target="mainFrame"><b><?php echo $userdata['username']; ?></b></a>.<br />
</span>
</td>
</tr>
</table>
<span class="gensmall">
<a href="<?php echo $phpbb_root_path; ?>privmsg.php?folder=inbox" target="mainFrame" ><?php if ($userdata['user_new_privmsg']) { echo $userdata['user_new_privmsg']; } else { echo 'No'; } ?> new message<?php echo $userdata['user_new_privmsg'] == 1 ? '' : 's' ?></a><br />
<a href="<?php echo $phpbb_root_path; ?>search.php?search_id=newposts" target="mainFrame" >Posts since last visit
(<?php echo $new_posts['total']; ?>)</a>
<br />
<!-- <a href="<?php echo $phpbb_root_path; ?>login.php?logout=true&redirect=../Forum/mods/phpbb_fetch_all/examples/login.php" target="_self" >Logout</a> -->
<a href="<?php echo $phpbb_root_path; ?>login.php?logout=true&redirect=../Forum/mods/phpbb_fetch_all/examples/login.php" target="_self" >Logout</a>
<?php } else { ?>
<span class="gensmall">
<form action="<?php echo $phpbb_root_path; ?>login.php" method="post" target="_self">
Username:<br />
<input type="text" class="post" name="username" size="20" maxlength="40" value="" /><br />
Password:<br />
<input type="password" class="post" name="password" size="20" maxlength="25" /><br />
<input type="checkbox" name="autologin" checked="checked" />
auto login<span class="gensmall">
<input type="hidden" class="mainoption" name="redirect" value="../Forum/mods/phpbb_fetch_all/examples/login.php" />
</span><br />
<div align="center"><input type="submit" class="mainoption" name="login" value="Login" /><br />
<a href="<?php echo $phpbb_root_path; ?>profile.php?mode=sendpassword" target="mainFrame" >I forgot my password</a></div>
</form>
<a href="<?php echo $phpbb_root_path; ?>profile.php?mode=register" target="mainFrame" class="postlink" >Register!</a>
</span>
<?php } ?>
</td>
</tr>
</table>
</td>
</tr>
</table>
<?php } ?>
<!-- USER -->