php page refresh

Discussion in 'PHP' started by knish, Nov 19, 2007.

  1. #1
    Hi,

    Find attached a page image. Initially, when user goes to the link, without this code the page shows not needed display. Whereas what is needed is when I press the button go. So, I included that in the if condition. However, it is not working as needed. How is it possible to see it working and be happy and make others happy here.

    $currentPage = $_SERVER["PHP_SELF"];

    if (!isset($_GET['Submit']))
    {
    $host = $_SERVER['HTTP_HOST'];
    $uri = rtrim(dirname($_SERVER['PHP_SELF']), '/\\');
    $pagename = 'search_Disp_03.php?Proj_Name=Any&Sequ_Name=Any&Shot_Name=Any&Artist_Name=Any&Dept_Name=Any&Name_Of_Project=Go';
    # header("location: http://renderunit-19/dailies/search_Disp_03.php?Proj_Name=Any&Sequ_Name=Any&Shot_Name=Any&Artist_Name=Any&Dept_Name=Any&Name_Of_Project=Go");
    header("location: http://$host$uri/$pagename/");
    exit;
    }
     
    knish, Nov 19, 2007 IP