Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New Coder
    Join Date
    Nov 2005
    Posts
    93
    Thanks
    5
    Thanked 0 Times in 0 Posts

    Need Help on redirection using PHP

    Hi.

    I have a page that displays employee data(display.php)

    at the bottom of the page i have "add new employee button" this is a form for creating a new employee record.(newemployee.php)

    now i want the form(newemployee .php) to redirected back to display.php after the new employee form is submitted.

    how can i do this?

    I tried using
    <form name="" method="post" action="display.php">

    after the newemployee.php page is submitted i get a blank page.But the browser address bar shows that its on newemployee.php

    Thanks.

  • #2
    New Coder
    Join Date
    Jul 2007
    Posts
    26
    Thanks
    1
    Thanked 0 Times in 0 Posts
    Submit your form to newemployee.php then in this file add the following

    PHP Code:
    Header("Location: display.php"); 
    More info at: http://us.php.net/header
    -


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •