Documentation

Basics  Forms  Shortcuts and URLs  Modules  Miscellaneous  Other  

General Settings  Specials  eGroups  Message Boards  SEO  Auctions  Bookmarks  Products  Partners  Email Marketing Campaigns  

Product Search  Functions And Indexes  Product Module  Manage Products  

Product Search

Products - Build Product Full Search

Parameters:

Link & Atom pair

Navigator Prefix

No Results Snippet

Service Code

Order Column

Order Type

Order Numeric Flag

 

Input Fields:

TG_KE_DIRECTORY

TG_KE_PARTNER

TG_PRODUCT_SEARCH_ATOM_HOME

TG_PRODUCT_SEARCH_NAME

TG_PRODUCT_SEARCH_KEYWORD

TG_PRODUCT_SEARCH_PRICE

TG_PRODUCT_SEARCH_COMPARE

TG_PRODUCT_SEARCH_MAX

TG_PRODUCT_SEARCH_COUNT

 

Field 1

TG_PRODUCT_SEARCH_FIELDNAME1

TG_PRODUCT_SEARCH_FIELDVALUE1

TG_PRODUCT_SEARCH_FIELDMAX1

TG_PRODUCT_SEARCH_FIELDSIGN1

TG_PRODUCT_SEARCH_FIELDCOMPARE1

TG_PRODUCT_SEARCH_FIELDINSIDE1

TG_PRODUCT_SEARCH_FIELDTYPE1

 

Same for products 2-20

 

TG_KE_DIRECTORY – if present, search in specified directory and all tree below

TG_KE_PARTNER – if present, search only in products for specified partner

 

TG_PRODUCT_SEARCH_NAME – if present, search for product name

TG_PRODUCT_SEARCH_KEYWORD – if present, search in product code, product name, product description, directory name, directory description, directory keywords.

 

TG_PRODUCT_SEARCH_COMPARE

  – 0 – search for TG_PRODUCT_SEARCH_PRICE = PRODUCT_PRICE

  – -1 – search for TG_PRODUCT_SEARCH_PRICE < PRODUCT_PRICE

  – 1 – search for TG_PRODUCT_SEARCH_PRICE > PRODUCT_PRICE

TG_PRODUCT_SEARCH_MAX – if present, search for TG_PRODUCT_SEARCH_MAX < PRODUCT_PRICE

 

The following repeats for each field.

TG_PRODUCT_SEARCH_FIELDNAME1 – name of the field

TG_PRODUCT_SEARCH_FIELDTYPE1 – type of values

  1 – string

  2 – number

  3 – date

TG_PRODUCT_SEARCH_FIELDCOMPARE1

  – 0 – search for TG_PRODUCT_SEARCH_FIELDVALUE1 = field_value

  – -1 – search for TG_PRODUCT_SEARCH_FIELDVALUE1 < field_value

  – 1 – search for TG_PRODUCT_SEARCH_FIELDVALUE1 > field_value

TG_PRODUCT_SEARCH_FIELDMAX1 – if present, search for TG_PRODUCT_SEARCH_FIELDMAX1 < field_value

TG_PRODUCT_SEARCH_FIELDINSIDE1: for the sign between the two compares (value and value max)

  – 1 – OR

  – 2 – AND

TG_PRODUCT_SEARCH_FIELDSIGN1: for the sign between different fields

How to create a product full search:

- create navigator under products navigator set (not product directories)

- create the service with the appropriate builder and target

- assign values, if needed, to basic fields:

  TG_KE_DIRECTORY – directory and tree below

  TG_KE_PARTNER – partner code

  TG_PRODUCT_SEARCH_NAME – keyword for name

  TG_PRODUCT_SEARCH_KEYWORD – keyword for product name, product description, directory name, directory description, directory keywords (this will trigger OR: keyword in product name OR product description OR ....)

  TG_PRODUCT_SEARCH_PRICE, TG_PRODUCT_SEARCH_COMPARE and TG_PRODUCT_SEARCH_MAX – price filter (see below)

- all basic field will filter using AND, meaning: (product in directory) AND (product belong to partner) AND (name found in product name) AND...

 

For this example, we'll use two custom fields and the search will do: search for the input value into values, as string, of custom fields 'isbn' and 'title' and find it in either one of them.

TG_PRODUCT_SEARCH_FIELDNAME1='isbn' (from data configuration)

TG_PRODUCT_SEARCH_FIELDVALUE1 – from input field

TG_PRODUCT_SEARCH_FIELDMAX1 – not used

TG_PRODUCT_SEARCH_FIELDSIGN1=1 (OR)

TG_PRODUCT_SEARCH_FIELDCOMPARE1=1 (indexof for the input value in the values of isbn)

TG_PRODUCT_SEARCH_FIELDINSIDE1 – not used

TG_PRODUCT_SEARCH_FIELDTYPE1=1 (string)

 

TG_PRODUCT_SEARCH_FIELDNAME1='title' (from data configuration)

TG_PRODUCT_SEARCH_FIELDVALUE1 – from input field

TG_PRODUCT_SEARCH_FIELDMAX1 – not used

TG_PRODUCT_SEARCH_FIELDSIGN1=1 (OR)

TG_PRODUCT_SEARCH_FIELDCOMPARE1=1 (indexof for the input value in the values of title)

TG_PRODUCT_SEARCH_FIELDINSIDE1 – not used

TG_PRODUCT_SEARCH_FIELDTYPE1=1 (string)

 

For this example, we'll use two custom fields and the search will do: search product who have ('distributor_price' between FIELDVALUE1 and FIELDMAX1, as numbers) AND ('date_released' between FIELDVALUE2 and FIELDMAX2, as dates)

TG_PRODUCT_SEARCH_FIELDNAME1='distributor_price' (from data configuration)

TG_PRODUCT_SEARCH_FIELDVALUE1 – from input field

TG_PRODUCT_SEARCH_FIELDMAX1 – from input field

TG_PRODUCT_SEARCH_FIELDSIGN1=2 (AND)

TG_PRODUCT_SEARCH_FIELDCOMPARE1=-1 (product 'distributor_price' is greater as input field)

TG_PRODUCT_SEARCH_FIELDINSIDE1=2 (AND)

TG_PRODUCT_SEARCH_FIELDTYPE1=2 (number)

 

TG_PRODUCT_SEARCH_FIELDNAME1='date_released' (from data configuration)

TG_PRODUCT_SEARCH_FIELDVALUE1 – from input field

TG_PRODUCT_SEARCH_FIELDMAX1 – from input field

TG_PRODUCT_SEARCH_FIELDSIGN1=2 (AND)

TG_PRODUCT_SEARCH_FIELDCOMPARE1=-1 (product 'date_released' is greater as input field)

TG_PRODUCT_SEARCH_FIELDINSIDE1=2 (AND)

TG_PRODUCT_SEARCH_FIELDTYPE1=3 (date)