How to edit the code of the search form

To get full code of search form and edit fields of it, uncheck the checkbox "Short code".


The form code becomes:

<script charset="UTF-8" type="text/javascript">
window.TP_FORM_SETTINGS = window.TP_FORM_SETTINGS || {};
window.TP_FORM_SETTINGS["51226f99649ab833e300000a"] = {
"handle": "51226f99649ab833e300000a",
"widget_name": "Wix",
"border_radius": "5",
"additional_marker": "wix",
"width": 940,
"show_logo": true,
"show_hotels": true,
"form_type": "avia_hotel",
"locale": "en",
"currency": "usd",
"sizes": "default",
"search_target": "_parent",
"active_tab": "avia",
"search_host": "",
"hotels_host": "",
"hotel": {
"name": "Ритц-Карлтон Москва",
"location": "",
"hotels_count": " отелей",
"search_id": "333601",
"search_type": "hotel"
"hotel_alt": "Hotellook - best prices on hotels worldwide. Compare prices across 30 booking websites and save on your hotel.",
"avia_alt": "",
"id": 316,
"marker": "16886.wix",
"origin": {
"name": "Moscow",
"iata": "MOW"
"destination": {
"name": "Berlin",
"iata": "BER"
"color_scheme": {
"name": "white_blue",
"icons": "icons_blue",
"background": "#ffffff",
"color": "#000000",
"border_color": "#cccccc",
"button": "#03bae4",
"button_text_color": "#ffffff"
"hotels_type": "hotellook_host",
"best_offer": {
"locale": "en",
"currency": "usd",
"marker": "16886.wix",
"search_host": "",
"offers_switch": false,
"api_url": "//",
"routes": []
"hotel_logo_host": "",
"search_logo_host": "",
"hotel_marker_format": "marker=",
"hotelscombined_marker": null
<script charset="UTF-8" src="//"></script>

Parameters of search form

  • handle - a unique id form (can’t be modified!).
  • widget_name - form name.
  • border_radius - rounding radius of borders.
  • additional_marker - additional marker.
  • width - width of form.
  • show_logo - display a logo of Aviasales (if true).
  • show_hotels - display hotels search tab.
  • form_type - type of form (only air, only hotels and mixed).
  • locale - language of form.
  • currency - select the currency to display in search results.
  • sizes - responsible for size of the form (a / compact).
  • search_target - how search opens (in a new window, in a new tab, in the same window).
  • active_tab - name of the active tab by default.
  • search_host - site where flight search results open (can be specified in your White Label).
  • hotels_host - site where hotel search results open (can be specified in your White Label).
  • hotel - information about default hotel.
  • powered_by - adds a link Powered by Travelpayouts under the search form. More details in the article Referral program.
  • id - service parameter.
  • marker - affiliate marker.
  • origin - name or IATA code for point of departure. IATA code is shown by uppercase letters, for example, MOW.
  • destination - name or IATA code for flight destination. IATA code is shown by uppercase letters, for example, MOW.
  • color_scheme - color scheme of form.
  • hotels_type - service parameter.
  • best_offer - settings of a block "Best Offer".
  • hotel_logo_host - service parameter.
  • search_logo_host - service parameter.
  • hotel_marker_format - service parameter.
  • hotelscombined_marker - service parameter.
  • responsive - paste true if this form is responsive.

Pay attention! If you are working with the full version of a code, you must make changes in the code directly on the page where it is embedded.

Was this article helpful?

Have more questions? Submit a request