Results 1 to 6 of 6

Thread: multiple pages

  1. #1
    Join Date
    Apr 2004
    Location
    Michigan
    Posts
    44

    Unanswered: multiple pages

    hey guys,
    I am trying to create a multiple page applicaiton form..
    so what I was doing is application1.php, application2.php, application3.php

    now its split into 3 parts..
    and I was forwarding session from one to another...
    but then, I want the url to be like this
    http://localhost/application.php?page=1
    and if i go page two, it will be http://localhost/application.php?page=2
    and so on..

    well, what i have now is application1.php and i go page 2..it will have as url application2.php

    so I was wondering if anyone know the concept behind what I desire?

    thanks

  2. #2
    Join Date
    Jan 2004
    Posts
    12
    You mean something like this?

    PHP Code:
    <?php

    if (isset($_GET['page']))
    {
        
    header('Location: ./application'.$_GET['page'].'.php');
    }

    ?>

  3. #3
    Join Date
    Sep 2003
    Location
    So. Cal. USA
    Posts
    142
    Hi... I don't know if this is exactly what you want, but you can have all 3 pages on the same .php document which only shows page 1 info when page=1, page 2 info when page=2, etc and just keep submitting to itself until the web user is done.
    --ST

  4. #4
    Join Date
    Jan 2004
    Location
    India
    Posts
    168
    Ya Steve you are correct. The way he wants is not that clear b'coz there are a lot option to do this. You can even have a page called application.php which will get the page no on which we can find which page he wants to get. If he wants to get the page on submit of the previous page then he can use a hidden field that stores the page no.
    Hope you can use any of these option.
    If you are not clear get back to us... with little more details.

    Regards
    Rajesh

  5. #5
    Join Date
    Feb 2004
    Posts
    29
    ermau is right, kicker22 just retrieve the value of page variable
    Code:
    <?php 
    if (($_GET['page']==1)) 
    { 
        header('Location: ./application'.$_GET['page'].'.php'); 
    } 
    
    ?>
    you are using form data kicker22 so why are you not using simple form. suppose you are on "application1.php" page
    Code:
    <form action="application2.php" method="post">
    ----------
    -------------
    ---------------
    </form>
    
    for third page
    
    <form action="application3.php" method="post">
    ----------
    -------------
    ---------------
    </form>
    pose your complete code if you are still getting problem.

  6. #6
    Join Date
    Dec 2003
    Location
    Houston, TX
    Posts
    21
    Quote Originally Posted by Steve T.
    Hi... I don't know if this is exactly what you want, but you can have all 3 pages on the same .php document which only shows page 1 info when page=1, page 2 info when page=2, etc and just keep submitting to itself until the web user is done.
    --ST
    this is a good idea as well .. i like having it all on one page~!
    I do not fear computers. I fear the lack of them.
    -Isaac Asimov (1920 - 1992)

Posting Permissions

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