# Php loading to next page using if statement

**URL:** <https://forum.kirupa.com/t/php-loading-to-next-page-using-if-statement/207505>\
**Category:** Uncategorized\
**Created:** [November 18, 2006, 9:07am UTC](https://forum.kirupa.com/t/php-loading-to-next-page-using-if-statement/207505 "2006-11-18T09:07:10Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![flagbarton](https://avatars.discourse-cdn.com/v4/letter/f/3ec8ea/32.png) [@flagbarton](https://forum.kirupa.com/u/flagbarton)\
**Post date:** [November 18, 2006, 9:07am UTC](https://forum.kirupa.com/t/php-loading-to-next-page-using-if-statement/207505/1 "2006-11-18T09:07:10Z")

</div>

hello guyz i have a problem loading to next page of my works, this is the code…

\<form name=“form1” method=“post” action=“submit.php”\>  
\<input type=“text” name=“user” size=“15”\>  
\<input type=“text” name=“pass” size=“15”\>  
\<input type =“submit” value=“send”\>  
\</fom\>  
\<?  
$txt1=$\_POST[‘user’];  
$txt2=$\_POST[‘pass’];  
$user = “myuser”;  
$pass = “mypass”;  
if ($tx1t==$user And $txt2==$pass){  
//after verification i want to go to the nxt page if  
//statement returns true  
}  
else { echo"user or password invalid"}  
?\>
