Instead of hard coding the name of a script use a superglobal reference. <form action="<?php echo $_SERVER['PHP_SELF']; ?>"...

read more