customize search: multiple attributes in the GET request

Author Message

Stefano Vaghi

Thursday 31 July 2008 6:36:24 am

Hi, I have customized advancedsearch.tpl to create mypersonalsearch.tpl with the following lines to search only in the section 7, among the document with 43 as id.

<input type="hidden" name="SearchSectionID" value="7" />
<input type="hidden" name="SearchContentClassID" value="43" />

Moreover,I need to search between 2 attributes of the documents and so I added these other lines:

<input type="hidden" name="SearchContentClassAttributeID" value="331" />
<input type="hidden" name="SearchContentClassAttributeID" value="332" />

Unfortunately, in this way, the search uses only the second attribute (332)...how can I pass all the attributes to the "get"?

Thanks in advance for suggestions.

Ivo Lukac

Thursday 31 July 2008 7:40:51 am

Hi stefano,

You can try with this:

<input type="hidden" name="SearchContentClassAttributeID[]" value="331" />
<input type="hidden" name="SearchContentClassAttributeID[]" value="332" />

but I think that engine support only 1 attribute...

http://www.linkedin.com/in/ivolukac
http://www.netgen.hr/eng/blog
http://twitter.com/ilukac

Stefano Vaghi

Monday 04 August 2008 1:19:55 am

Thanks for your advice...it seems to work...I am going to analyze the code of ezsearch.php.

Bye

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 18 2025 18:31:40
Script start
Timing: Jan 18 2025 18:31:40
Module start 'layout'
Timing: Jan 18 2025 18:31:40
Module start 'content'
Timing: Jan 18 2025 18:31:41
Module end 'content'
Timing: Jan 18 2025 18:31:41
Script end

Main resources:

Total runtime0.9754 sec
Peak memory usage4,096.0000 KB
Database Queries57

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0050 588.1563152.6563
Module start 'layout' 0.00500.0033 740.812539.5078
Module start 'content' 0.00830.9656 780.3203536.4844
Module end 'content' 0.97390.0015 1,316.804712.0938
Script end 0.9754  1,328.8984 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00310.3215160.0002
Check MTime0.00140.1485160.0001
Mysql Total
Database connection0.00070.070510.0007
Mysqli_queries0.927595.0852570.0163
Looping result0.00070.0681550.0000
Template Total0.946597.020.4733
Template load0.00220.224620.0011
Template processing0.944396.814920.4722
Template load and register function0.00020.020410.0002
states
state_id_array0.00080.080610.0008
state_identifier_array0.00100.106120.0005
Override
Cache load0.00180.1885200.0001
Sytem overhead
Fetch class attribute can translate value0.00180.181420.0009
Fetch class attribute name0.00140.139140.0003
XML
Image XML parsing0.00070.076720.0004
class_abstraction
Instantiating content class attribute0.00000.001140.0000
General
dbfile0.00140.1479170.0001
String conversion0.00000.000840.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
3content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
6content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
2content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
1content/datatype/view/ezxmltags/literal.tpl<No override>extension/community/design/standard/templates/content/datatype/view/ezxmltags/literal.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 15
 Number of unique templates used: 7

Time used to render debug report: 0.0001 secs