Forums / Extensions / eZ Find / How to have all keywords in facets list

How to have all keywords in facets list

Author Message

Nicolas Jessel

Monday 07 December 2009 12:43:03 am

Hello,

I would like to have, in my facets, all keywords for each classes.

In facets array, we have this:

facets[]=array( 'field' => 'article/tags');

But this fetch only keywords in tags attribute for article class.

Nicolas Pastorino given me a solution:

facets[]=array( 'field' => 'attr_tags_k');

And with that it's working fine, thanks to him.

Bye.

Nicolas Pastorino

Monday 07 December 2009 1:19:15 am

Hi Nicolas,

Indeed, the normal selector for pointing to a Solr field takes the following form:

<content-class>/<content-attribute>/[<subattribute>]

meaning that pointing to a content attribute necessarily narrows the results down to a given content class. The following syntax is not yet supported:

*/<content-attribute>

and can be "simulated" by directly passing the solr field name, as shown by Nicolas above.

--
Nicolas Pastorino
Director Community - eZ
Member of the Community Project Board

eZ Publish Community on twitter: http://twitter.com/ezcommunity

t : http://twitter.com/jeanvoye
G+ : http://plus.tl/jeanvoye

Franck Grenier

Tuesday 29 December 2009 6:41:05 am

Hello,

I'm having troubles with ezfind facets. I choose several 'catégories' on my 'news' content through an object relation attribute.

When I put this 'catégories' facet in ezfind, the 'categories" are not parsed correctly and their titles are cut.

For example, my 'Sport/Loisrs' category returns two facets : 'Sports' and 'Loisirs'.

The search is still effective but I would like to have my full real category titles.

What's wrong ?

Developer at Open Wide

Paul Borgermans

Saturday 02 January 2010 12:14:57 pm

Correct, better handling will be provided with ez find 2.2: attributes are indexed in the same way for searching and faceting currently (ez find 2.1). In the next release, for a single attribute, multiple fields can be created that have optimal behaviour for searching/filtering versus faceting/sorting. For object relation attributes, this will be possible for meta-data as well as their respective atttributes.

Paul

eZ Publish, eZ Find, Solr expert consulting and training
http://twitter.com/paulborgermans

Lars Eirik R

Wednesday 19 May 2010 2:22:43 am

Hi.

Is there a way to append the template code array to have ezfind search across all classes that have a tag.

I have sucessfully modified the php function code which is called by the ezfind operator for search.

Is there a way for me in my template do modifications to this array or do i need to fix it in the php file?

I changed the keywords so that only acets[]=array( 'field' => 'attr_tags_k') ; is now added to the facets array in the php function getDefaultFacets.

Any pointers on how to do this in template code would be nice.

eZ debug

Timing: Jan 17 2025 23:45:11
Script start
Timing: Jan 17 2025 23:45:11
Module start 'content'
Timing: Jan 17 2025 23:45:11
Module end 'content'
Timing: Jan 17 2025 23:45:12
Script end

Main resources:

Total runtime0.5957 sec
Peak memory usage4,096.0000 KB
Database Queries208

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0079 592.5234180.7734
Module start 'content' 0.00790.4709 773.2969686.0547
Module end 'content' 0.47880.1168 1,459.3516337.0625
Script end 0.5956  1,796.4141 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00480.8046210.0002
Check MTime0.00180.2974210.0001
Mysql Total
Database connection0.00120.204810.0012
Mysqli_queries0.515186.46362080.0025
Looping result0.00220.36892060.0000
Template Total0.562394.420.2812
Template load0.00220.373020.0011
Template processing0.560194.025820.2801
Template load and register function0.00020.031410.0002
states
state_id_array0.00080.136510.0008
state_identifier_array0.00070.125720.0004
Override
Cache load0.00190.3240390.0000
Sytem overhead
Fetch class attribute can translate value0.00120.203060.0002
Fetch class attribute name0.00120.203880.0002
XML
Image XML parsing0.00200.331260.0003
class_abstraction
Instantiating content class attribute0.00000.003280.0000
General
dbfile0.00240.4025400.0001
String conversion0.00000.001230.0000
Note: percentages do not add up to 100% because some accumulators overlap

CSS/JS files loaded with "ezjscPacker" during request:

CacheTypePacklevelSourceFiles
CSS0extension/community/design/community/stylesheets/ext/jquery.autocomplete.css
extension/community_design/design/suncana/stylesheets/scrollbars.css
extension/community_design/design/suncana/stylesheets/tabs.css
extension/community_design/design/suncana/stylesheets/roadmap.css
extension/community_design/design/suncana/stylesheets/content.css
extension/community_design/design/suncana/stylesheets/star-rating.css
extension/community_design/design/suncana/stylesheets/syntax_and_custom_tags.css
extension/community_design/design/suncana/stylesheets/buttons.css
extension/community_design/design/suncana/stylesheets/tweetbox.css
extension/community_design/design/suncana/stylesheets/jquery.fancybox-1.3.4.css
extension/bcsmoothgallery/design/standard/stylesheets/magnific-popup.css
extension/sevenx/design/simple/stylesheets/star_rating.css
extension/sevenx/design/simple/stylesheets/libs/fontawesome/css/all.min.css
extension/sevenx/design/simple/stylesheets/main.v02.css
extension/sevenx/design/simple/stylesheets/main.v02.res.css
JS0extension/ezjscore/design/standard/lib/yui/3.17.2/build/yui/yui-min.js
extension/ezjscore/design/standard/javascript/jquery-3.7.0.min.js
extension/community_design/design/suncana/javascript/jquery.ui.core.min.js
extension/community_design/design/suncana/javascript/jquery.ui.widget.min.js
extension/community_design/design/suncana/javascript/jquery.easing.1.3.js
extension/community_design/design/suncana/javascript/jquery.ui.tabs.js
extension/community_design/design/suncana/javascript/jquery.hoverIntent.min.js
extension/community_design/design/suncana/javascript/jquery.popmenu.js
extension/community_design/design/suncana/javascript/jScrollPane.js
extension/community_design/design/suncana/javascript/jquery.mousewheel.js
extension/community_design/design/suncana/javascript/jquery.cycle.all.js
extension/sevenx/design/simple/javascript/jquery.scrollTo.js
extension/community_design/design/suncana/javascript/jquery.cookie.js
extension/community_design/design/suncana/javascript/ezstarrating_jquery.js
extension/community_design/design/suncana/javascript/jquery.initboxes.js
extension/community_design/design/suncana/javascript/app.js
extension/community_design/design/suncana/javascript/twitterwidget.js
extension/community_design/design/suncana/javascript/community.js
extension/community_design/design/suncana/javascript/roadmap.js
extension/community_design/design/suncana/javascript/ez.js
extension/community_design/design/suncana/javascript/ezshareevents.js
extension/sevenx/design/simple/javascript/main.js

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
5content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
7content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
3content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
2content/datatype/view/ezxmltags/literal.tpl<No override>extension/community/design/standard/templates/content/datatype/view/ezxmltags/literal.tplEdit templateOverride template
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/pagelayout.tplEdit templateOverride template
 Number of times templates used: 19
 Number of unique templates used: 6

Time used to render debug report: 0.0002 secs