Jump to content

noobism

New Members
  • Posts

    1
  • Joined

  • Last visited

    Never

Posts posted by noobism

  1. I really need help! I am working on a hotel booking site but i am stumped on how to perform a simple check on a startdate and an end date a user enters to see if there are any types of rooms availble that they have specified.

     

    For instance they enter the start and end date on the form together with the number of adults & children that will be staying and select various room options such as smoking, non-smoking, PC' or network connection required and finally the type of room, single, double & conference hall etc. Currently there are 10 single rooms and 10 double rooms with 3 conference halls. I wish to use this data to check the database for any bookings which collide in between those given dates for their chosen room type and then return some sort of feed back to the user letting them know that there are no single rooms availble for example in those 2 dates. I am developing the site through dreamweaver at the moment.

     

    The rooms table consists of the following

     

    RoomID (auto incremented)

    Price

    noBeds

    Description

    roomNumber

     

    the bookings table has the following information

     

    bookingID

    customerID

    roomID

    startDate

    endDate

    adults

    children

    roomOptions

     

     

     

    All most forgot the dates are entered in the following format yyyy-mm-dd. Also if the room is availble I wish for the user to be taken to a confirm bookings page which takes the values added on the previous form and has them availble on the new page for confirmation.

     

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.