How to Create a Widget for a Hotel Search

Example of Widget for Hotel Search

 

Syntax of Code

<script type=”text/javascript” src="Scheme://HOST_HEADER/UI_NET/WidgetProvider.ashx? page=HotelsSearch/HotelsSearch.aspx&destination=destination&culture=culture&renderCss=false

&renderJqueryLib=false&datefrom=ddmmmyy&dateto=ddmmmyy&rand=[x]"></script>

 

An example of the above syntax populated with values is as follows:

<script type=”text/javascript” src="http://b2c-my.TB.host.header.com/UI_NET/WidgetProvider.ashx? page=HotelsSearch/HotelsSearch.aspx&destination=Amsterdam&culture=en-US&renderCss=false

&renderJqueryLib=false&datefrom=19Jul12&dateto=25Jul12&rand=3"></script>

Parameters

Name

Description Comments
Scheme Http OR Https  
HOST_HEADER The host header of the B2C site.  
destination

The hotel destination.

For example: Amsterdam

If not defined, the drop-down list will display all destinations.
The destination defined must also be included in the visible destination entries.
culture

The language in which results will be displayed.

For example: en-US

If Hebrew (he-IL) is defined, the widget will be positioned from right to left.
renderCss Indicates whether to render the default CSS for the widget. The default value is true.
renderJqueryLib Indicates whether to render jQuery CSS and JS for the widget. The default value is true.
datefrom

The default check-in date.

For example: 19Jul12

Date format: ddMMMyy

dateto

The default check-out date.

For example: 25Jul12

Date format: ddMMMyy

rand

Random parameter used in order to avoid client-side caching.

A different value must be used for each unique widget definition.