Problems returning blog entries

Author Message

Kaustav Bhattacharya

Monday 15 December 2008 12:13:09 pm

I've got an eZ 4.0.1 site on which I'm using an eZ Blog. I want to display the blog title and a short excerpt of each blog entry which matches a particular tag. So for example I have posted a blog entry about "Fred Smith" and on the "profile page" of Fred Smith I want to pull out the titles of all the blogs that were ever written about Fred Smith and tagged with Fred Smith in my eZ blog. So far my code look like the following, but the search returns zero research. Any advice?

 

  {attribute_view_gui attribute=$node.object.data_map.center_column}
					{def $thisnode=$node.node_id}
					{def $nodes=fetch( 'content', 'node',
					hash( 'node_id', $thisnode, limit, '9'))}
					{def $name = $nodes.data_map.name.value}
					<h1>Recent posts about {$name}</h1>
					
					{def $search=fetch( 'content', 'search',
										hash( 'text',     '$name',
											  'class_id', array( '13', '19', '20' ) ) )}
					 
					The search returned {$search.SearchCount} matches. <br />
					 
					{foreach $search.SearchResult as $matched_node}
						{$matched_node.name|wash} <br />
					{/foreach} 

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 16:22:41
Script start
Timing: Jan 18 2025 16:22:41
Module start 'layout'
Timing: Jan 18 2025 16:22:42
Module start 'content'
Timing: Jan 18 2025 16:22:42
Module end 'content'
Timing: Jan 18 2025 16:22:42
Script end

Main resources:

Total runtime0.9540 sec
Peak memory usage4,096.0000 KB
Database Queries46

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0051 589.0313152.6250
Module start 'layout' 0.00510.0036 741.656339.4453
Module start 'content' 0.00880.9437 781.1016401.4297
Module end 'content' 0.95250.0014 1,182.53138.1641
Script end 0.9539  1,190.6953 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00340.3538160.0002
Check MTime0.00150.1616160.0001
Mysql Total
Database connection0.00060.059710.0006
Mysqli_queries0.921196.5552460.0200
Looping result0.00040.0406440.0000
Template Total0.925897.020.4629
Template load0.00210.215520.0010
Template processing0.923796.825520.4618
Template load and register function0.00020.022610.0002
states
state_id_array0.00060.064310.0006
state_identifier_array0.00090.091820.0004
Override
Cache load0.00160.172960.0003
Sytem overhead
Fetch class attribute can translate value0.00040.045010.0004
Fetch class attribute name0.00060.067510.0006
XML
Image XML parsing0.00010.012710.0001
class_abstraction
Instantiating content class attribute0.00000.000410.0000
General
dbfile0.00050.0569100.0001
String conversion0.00000.000740.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
1content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
1content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.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: 5
 Number of unique templates used: 5

Time used to render debug report: 0.0001 secs