9.2.8 "Advanced Search"-form

9.2.8 "Advanced Search"-form  <<  >> Arranging Search Results Form Definitions and Required Input Fields.

Advanced search HTML-form shoud be defined like this:

<form accept-charset="UTF-8" method="POST" name="AdvancedSearch" action="PublishedService" encoding="UTF-8" enctype="application/x-www-form-urlencoded"> 

Required input-fields on form:
<input name="file" value="page" type="hidden">
<input name="pageID" value="20" type="hidden">
<input name="action" value="advancedsearch" type="hidden">
<input name="advancedsearch.attributes" value="variable1, variable2, variable3" type="hidden">

DescriptionTypeAttribute name Values (value="..")Attribute name (name="...")
Just a technical necessity.hiddenpagefile
There are multiple types of pages. One of them is the search page, which has an ID of 20.hidden20pageID
The action performed by the Workspace depends on the incoming form data. The "advancedsearch" as an action value denotes that the action subject to undertaking is the execution of the searchengine.hiddenadvancedsearchaction
Variables for product fields used in product search. You can define multiple variables by separating theme with comma.hiddenvariable1advancedsearch.attributes
Table 9.1 : Required Input Fields

Every variable introduced in "advancedsearch.attributes"- field, should have its own input-fields. Field "advancedsearch.variable1.type" defines how search will be performed - should it get only exact matches or likely ones also. Field "advancedsearch.variable1.properties" defines what product fields this variable represents. Search will be performed on all these fields. Also multiple product fields can be defined for variable.

<input name="advancedsearch.variable1" type="text" value="">
<input name="advancedsearch.variable1.type" value="contains" type="hidden">
<input name="advancedsearch.variable1.properties" value="textInfo1,textInfo2,textInfo3,textInfo4" type="hidden">

DescriptionAttribute name Values (value="..")Attribute name (name="..")
Search fieldadvancedsearch.variable1
Search type. Search results contain search keyword.containsadvancedsearch.variable1.type
Search type. Search results start with search keyword.startswith
Search type. Search results are exact matches of search keyword.exact
Search type. Search results, should be above this min. value. (Search keyword should be numerical. For example price.)minvalue
Search type. Search results should be below max. value. (Search keyword should be numerical. For example price.)maxvalue
Search type. Search results contain only those items which options match search keyword. No search properties required.option
Search from product itemcode fielditemCodeadvancedsearch.variable1.properties
Search from product name fieldname
Search from product price fieldprice
Search from product VAT % fieldvat
Search from product unitprice fieldunitPrice
Search from product unit type fielduntiType
Search from product packet type fieldpacketType
Search from product packet type fieldpaketSize
Search from product supplier id fieldsupplierId
Search from product supplier name fieldsupplierName
Search from product supplier itemcodesupplierItemCode
Search from product manufacturer id fieldmanufacturerId
Search from product manufacturer name fieldmanufacturerName
Search from product manufacturer itemcodemanufacturerItemCode
Search from product pictures alt-textspicture1Alt ... picture5Alt
Search from product file linktextsfile1LinkText ... file5LinkText
Search from product titlestitle1 ... title4
Search from product slogansslogan1 ... slogan4
Search from product info textstextInfo1 ... textInfo4
Search from product openfieldsopenField1 ... openField20
Search from productgroup with groupcodegroupcode defined in product manager's productgroupeditoradvancedsearch.groupcode
Search from productgroup with group's database idGroup id used in databaseadvancedsearch.gid
Search from product group with group pathComplete productgroup pathadvancedsearch.path
Table 9.2 : Attributes for defining search criterias