Page 2 of 2 FirstFirst 12
Results 11 to 12 of 12

Thread: One more PHP question

  1. #11
    Senior Member
    Join Date
    Apr 2004
    Posts
    228
    The user for the website doesn't have many permisions on the site. Actualy, nothing more then read or add records
    Don\'t post if you\'ve got nothing constructive to say. Flooding is annoying

  2. #12
    Senior Member
    Join Date
    Apr 2004
    Posts
    228
    I thought to start a new thread, but hope someone'll read the question here. If not. I'll repost it.

    Could you help me with the next code:

    <?php

    require ("Functions.php");

    #geting the destinations
    $link = Connect();

    $destinations_query = "SELECT * FROM destinations
    WHERE Held_In_Destination > 1";

    $destinations_result = mysqli_query($link, $destinations_query);

    #creating a form containing a destination list.
    #The form will pass on a destination ID to the next form
    #that shows hotels in the area.

    echo "<form action='MakeAnOrder.php' method='POST'>

    <strong>Select Your Destination</strong>
    <select name='Destination_Name'>\n";

    while ($destinations_row = mysqli_fetch_array($destinations_result))
    {

    extract ($destinations_row);
    echo"<option value = '$Destination_Name'>$Destination_Name\n";

    }


    echo"</select>\n";
    echo "<input type = 'submit' value = 'Select'>
    </form>\n";


    #Selecting a hotel

    $hotels = Hotels(isset($_POST['$Destination_ID']));

    echo "<form action='MakeAnOrder.php' method='POST' >

    <strong>Select a Hotel</strong>
    <select name='Hotel_Name'>\n";

    while ($hotels_row = mysqli_fetch_array($hotels))
    {

    extract ($hotels_row);
    echo"<option value = '$Hotel_Name'>$Hotel_Name\n";

    }

    echo"</select>\n";
    echo "<input type = 'submit' value = 'Select'>
    </form>\n";

    ?>



    I am trying to influence the output of the second form by the users choice in the first one. Both are based in the same page.
    Don\'t post if you\'ve got nothing constructive to say. Flooding is annoying

Posting Permissions

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