In the booking form it is possible to preselect a product's start date, end date, duration and number of male, female and/or couple guests.
This can be done for any kind of product - flexible duration, flexible arrival, fixed date or duration variant products can all be preset.
To do so you must link directly to the product, add '?' to the end of the URL followed by any series of parameters that you wish to set with each parameter separated by an '&' symbol. Note that the order in which the parameters is passed does not make a difference and that all parameters are optional (i.e. if you include one parameter there is no requirement to pass all available parameters).
The optional parameters are:
- `start` which is in 'YYYY-MM-DD' format;
- `end` also in 'YYYY-MM-DD' format;
- `duration` as integer;
- `male` integer of number of males;
- `female` integer of number of females; and
- `couple` integer of number of couples.
For example, a product located at
could be preset with a check in date of 18/06/2017, check out date of 28/06/2017, 3 female guests and 1 couple by the URL:
If you are pre-setting dates you will need to take a look at the product on the booking form to know whether you will need to pass a start & end date or a start date & duration:
- if you see a date range picker with start date and end date then in your URL you'll have to include both the start and end date.
- if you see either a single date picker or no date picker at all you just pass start date and duration.
Pre-setting number of guests:
There are three different kinds of guests that can be preset: males, females and couples.
For example to preset 2 males: https://yourbusiness.bookinglayer.io/frontoffice/#/product/256?male=2
To preset 6 males, 8 females & 1 couple: https://yourbusiness.bookinglayer.io/frontoffice/#/product/375?female=8&male=6&couple=1