How to change calendar check in and check out date same day

Discuss everything related to PHP Hotel Site. All versions. Any questions related to the PHP Hotel Site developing or using should be posted to this forum.

Moderator: alexandrleonenko

hlmyhlm
Newbie
Newbie
Posts: 8
Joined: Dec 1st, '16, 16:44

How to change calendar check in and check out date same day

Postby hlmyhlm » Jan 19th, '17, 15:36

Hi,

I have tried to search this forum about this but cannot find anything similar to my issue here. I have tried to change : $min_nights * 24 * 60 * 60 in Rooms.class.php to $min_nights * 0 * 60 * 60 so that the date will appear on same day. This is to enable my client to book room for half day (not one night). There is 'message about minimum one night' . The Minimum Nights Stay in mod_booking_settings only allow me to change to minimum number of '1'. How to change to minimum night to '0'?

Thank you in advance.

administrator
Site Admin
Site Admin
Posts: 6011
Joined: Jan 7th, '09, 23:18
Contact:

Re: How to change calendar check in and check out date same day

Postby administrator » Jan 20th, '17, 08:17

It's impossible.
If you book room from today 12:00 to tomorrow 12:00 - it's exactly 1 day.

hlmyhlm
Newbie
Newbie
Posts: 8
Joined: Dec 1st, '16, 16:44

Re: How to change calendar check in and check out date same day

Postby hlmyhlm » Jan 23rd, '17, 02:20

administrator wrote:It's impossible.
If you book room from today 12:00 to tomorrow 12:00 - it's exactly 1 day.


Hi, Yes I understand it is impossible but can you point me to the codes where I can change the minimum 1 night to minimum 0 night?

Thank you.

ne_moj
Master
Master
Posts: 243
Joined: Jan 1st, '16, 14:11

Re: How to change calendar check in and check out date same day

Postby ne_moj » Jan 23rd, '17, 09:19

Hello hlmyhlm

I hope you will understand that we did not test this possibility.

You need to make a 2-fixes. 1st when checking on the server, you needs to edit the page/check_availability.php file (remove the check for one night). 2nd you need to touch up work calendar (javascrip-code), it is necessary to correct the code in the file include/classes/Rooms.class.php (function DrawSearchAvailabilityBlock())

hlmyhlm
Newbie
Newbie
Posts: 8
Joined: Dec 1st, '16, 16:44

Re: How to change calendar check in and check out date same day

Postby hlmyhlm » Jan 24th, '17, 13:40

Thank you. Will try that out.


Return to “ApPHP HotelSite / uHotelBooking Talk {developers/users}”