hi everyone,
Am a web developper in eco-tourism and i've just start to create database driver
website, where peoples can have a free quote to come on holiday in my country.
My problem is that, when someone request a quote after s/he has filled the quotation form. My php script need to check the arrival date when peoples will come. As in the hotel there's two seasons; one low and the other high. These two seasons have different prices. If s/he come in the low season the script give s/he the low prices else if s/he come in the high season s/he will have high prices.
Is there someone who can help please??
How can I select tariff in database depending on the date?
Moderator: General Moderators
How can I select tariff in database depending on the date?
hi..
There's nobody who can help me on that issue?
There's nobody who can help me on that issue?
Its fairly easy.
Store both sets of prices in a table
Then...
Psuedo code
NOTE: Please DO NOT bump a post half and hour after posting your question!! 
Store both sets of prices in a table
Then...
Psuedo code
Code: Select all
// Check current date
if( date > arrivalDate)
{
// select one set of prices
} else {
//select other set of prices
}[url=http://forums.devnetwork.net/viewtopic.php?t=30037]Forum Rules[/url] Section 1.1 wrote:3. Do not make multiple, identical posts. This is viewed as spam and will be deleted.
[url=http://forums.devnetwork.net/viewtopic.php?t=30037]Forum Rules[/url] Section 1.1 wrote:4. All users of any level are restricted to bumping (as defined here) any given thread within twenty-four (24) hours of its last post. Non-trivial posts are not considered bumping. A bump post found in violation will be deleted, and you may or may not recieve a warning. Persons bumping excessively be considered as spammers and dealt with accordingly.