Hi, I am very new to PHP development, so bare with me. My question is this:
I am currently designing a web page designed to take bookings, and I am not sure if this will be a simple task. Essentially what I need is code which can take down information from drop down menus and cross reference it with existing data in a database (MySQL) of other existing bookings. For example, a hotel and booking a room for a set number of days. Is this a simple task that can be answered? Is more information required? Or is there a place I can be referred to?
Concerning drop down menus (new to PHP)
Moderator: General Moderators
-
James.austin
- Forum Newbie
- Posts: 2
- Joined: Mon Feb 25, 2008 7:50 am
Re: Concerning drop down menus (new to PHP)
This would be simple for me to do - perhaps more complex for someone just starting.
The first step would be to build the webpage with the form that will post the information. I assume you've already got that.
Next, build the page the form posts to. It has to be able to gather the form data by pulling it out of $_POST, $_GET, or $_REQUEST. You can then put that form data in any number of queries & query your MySQL database.
It's not clear what you mean by cross-reference, but once you've got the form data & a connection to the database, you can do pretty much whatever you want with the data.
The first step would be to build the webpage with the form that will post the information. I assume you've already got that.
Next, build the page the form posts to. It has to be able to gather the form data by pulling it out of $_POST, $_GET, or $_REQUEST. You can then put that form data in any number of queries & query your MySQL database.
It's not clear what you mean by cross-reference, but once you've got the form data & a connection to the database, you can do pretty much whatever you want with the data.
Real programmers don't comment their code. If it was hard to write, it should be hard to understand.
-
James.austin
- Forum Newbie
- Posts: 2
- Joined: Mon Feb 25, 2008 7:50 am
Re: Concerning drop down menus (new to PHP)
Thanks,
what I meant by cross-referencing was that if for example, someone had booked for the first week of March and then someone else wanted to book the same room for some day during the first week of march, it would prevent them from doing so.
Thanks for the direction, I quite appreciate it.
what I meant by cross-referencing was that if for example, someone had booked for the first week of March and then someone else wanted to book the same room for some day during the first week of march, it would prevent them from doing so.
Thanks for the direction, I quite appreciate it.