Table of Contents

Quick Search method

Returns a list of hotels / places or countries by sending query string.

Query string is a string that user enters in quick search field. You can specify which lists do you want to return by defining types attribute.

This method is only available for content type dhotel

We urge you to use this CSV export files for regions and cities instead: ( Available languages: SI, EN, DE, HR, RS )

Valid content types

Description

public array quicksearch( array $searchData, array $headerData )

Parameters

Return Values

Gets a list of hotels, places and countries that matches query string.

Array
(
    [hotel] => Array
        (
            [0] => Array
                (
                    [code] => PL8415.200.2
                    [name] => PL8415.200.2 Dom Zdrojowy
                    [gid] => !interhome:IlBMODQxNS4yMDAuMiI=
                    [oid] => 17440
                    [hon] => Jastarnia
                    [cntyiso] => PL
                    [country] => Poland
                )

            [1] => Array
                (
                    [code] => PL8415.200.6
                    [name] => PL8415.200.6 Dom Zdrojowy
                    [gid] => !interhome:IlBMODQxNS4yMDAuNiI=
                    [oid] => 17440
                    [hon] => Jastarnia
                    [cntyiso] => PL
                    [country] => Poland
                )

        )

    [places] => Array
        (
            [0] => Array
                (
                    [oid] => 47032
                    [hon] => Busko Zdroj
                    [cntyiso] => PL
                    [country] => Poland
                )

            [1] => Array
                (
                    [oid] => 62847
                    [hon] => Wysowa ZdrĂłj
                    [cntyiso] => PL
                    [country] => Poland
                )

        )


    [regions] => Array
        (
            [0] => Array
                (
                    [code] => 100434
                    [name] => Kvarner
                )

            [1] => Array
                (
                    [code] => 99990088
                    [name] => Kvarner hribi
                )

        )        

    [countries] => Array
        (
            [0] => Array
                (
                    [code] => US
                    [name] => Združene države Amerike
                )

        )

Return parameters

Examples

$searchParams = array(
  'query' => 'zdr',       // search string
  'types' => 'hotel,places,countries,regions',       // type of lists to return
);
 
// this is the same as upper array (when types is empty then quicksearch returns all of the lists)
$searchParams = array(
  'query' => 'zdr',       // search string
);
 
$results = $soapClient->orsxml_dhotel_api_call( 'quicksearch', $searchParams, $header );
$searchParams = array(
  'query' => 'zdr',       // search string
  'types' => 'places',       // type of lists to return
);
 
$results = $soapClient->orsxml_dhotel_api_call( 'quicksearch', $searchParams, $header );
$searchParams = array(
  'query' => 'kvarner',       // search string
  'types' => 'regions',       // type of lists to return
);
 
$results = $soapClient->orsxml_dhotel_api_call( 'quicksearch', $searchParams, $header );