Jump to content

if statement not working


bob2006
 Share

Recommended Posts

i have been trying to figure this out for the last hour with no luck i am hopeing some one here can help me

the problem is well i really dont know what the problem is but the code should check is the passwords match if they dont it will tell you to reenter your password

if(isset($_POST['Submit']))
//isset open
{
$pass1=$_POST['pass1'];
$pass2=$_POST['pass2'];
if($pass1 != o)
//pass open
{
echo"<style type='text/css'>
<!--
body {
background-color: #FFFFFF;
}
body,td,th {
color: #000000;
}
-->
</style></head>

<body>
<table width='100%' border='1'>
  <tr>
    <td><center>Your Password Did Not Match Please Reenter Your Passwrods</center></td>
  </tr>
  <tr>
    <td><form id='form1' name='form1' method='post' action=''>
      <label>Password
      <input type='text' name='pass1' id='pass1' />
      </label>
    </td>
  </tr>
  <tr>
    <td>
      <label>Enter Password Again
      <input type='text' name='pass2' id='pass2' />
      </label>
    </td>
  </tr>
  <tr>
    <td>
      <label>
        <center><input type='submit' name='Submit' id='Submit' value='Submit' /></center>
        </label>
    </form>
    </td>
  </tr>
</table>
</body>";
die();
//pass colse
}
else
//pass else open
{
echo"
<form name='redirect'>
<center>
<font face='Arial'><b>Your Account Has Been Validated You Will Now Be Redirect To The Admin Home Page in<br><br>
<form>
<input type='text' size='3' name='redirect2'>
</form>
seconds</b></font>
</center>

<script>
<!--


//change below target URL to your own
var targetURL='/test1'
//change the second to start counting down from
var countdownfrom=5


var currentsecond=document.redirect.redirect2.value=countdownfrom+1
function countredirect(){
if (currentsecond!=1){
currentsecond-=1
document.redirect.redirect2.value=currentsecond
}
else{
window.location=targetURL
return
}
setTimeout('countredirect()',1000)
}

countredirect()
//-->
</script>";

//pass else close
}
//isset close
}

 

Link to comment
Share on other sites

This thread is more than a year old.

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.

 Share

×
×
  • 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.