Template syntax for forum posts order

Author Message

Eirik Alfstad Johansen

Monday 06 September 2004 6:16:29 am

Hi,

What's the template syntax for the forums posts order in the ez forum (meaning that the forum topic with the most recent forum reply is displayed first)?

Thanks in advance !

Sincerely,

Eirik Alfstad Johansen
http://www.netmaking.no/

Paul Borgermans

Monday 06 September 2004 6:57:24 am

Hi Eirik

There is nothing special, just a new sort method and attribute filter called 'modified_subnode' to be used in fetch(content,tree|list, hash(...,sort_by, ...))

hth

-paul

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

Ole Morten Halvorsen

Monday 06 September 2004 7:09:26 am

Hi Eirik,

I think this is what you are after:

{let child_list=fetch( 'content', 'list', hash( parent_node_id, $node.node_id,
                        limit, 20,
                        offset, $view_parameters.offset,
                        sort_by, array( array( modified_subnode, false() ) ) ) )}

Ole M.

Senior Software Engineer - Vision with Technology

http://www.visionwt.com
http://www.omh.cc
http://www.twitter.com/omh

eZ Certified Developer
http://ez.no/certification/verify/358441
http://ez.no/certification/verify/272578

Eirik Alfstad Johansen

Monday 06 September 2004 9:59:55 am

Thanks for enlightening me, guys!

Sincerely,

Eirik Alfstad Johansen
http://www.netmaking.no/

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 19 2025 07:07:46
Script start
Timing: Jan 19 2025 07:07:46
Module start 'layout'
Timing: Jan 19 2025 07:07:46
Module start 'content'
Timing: Jan 19 2025 07:07:48
Module end 'content'
Timing: Jan 19 2025 07:07:48
Script end

Main resources:

Total runtime1.5418 sec
Peak memory usage4,096.0000 KB
Database Queries62

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0069 589.2578152.6250
Module start 'layout' 0.00690.0034 741.882839.4453
Module start 'content' 0.01031.5300 781.3281588.1406
Module end 'content' 1.54030.0015 1,369.468812.1563
Script end 1.5418  1,381.6250 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00370.2403160.0002
Check MTime0.00150.1002160.0001
Mysql Total
Database connection0.00100.063410.0010
Mysqli_queries1.486496.4058620.0240
Looping result0.00070.0430600.0000
Template Total1.504697.620.7523
Template load0.00230.147220.0011
Template processing1.502397.439920.7512
Template load and register function0.00030.016710.0003
states
state_id_array0.00080.052510.0008
state_identifier_array0.00350.226920.0017
Override
Cache load0.00190.1232210.0001
Sytem overhead
Fetch class attribute can translate value0.00090.060630.0003
Fetch class attribute name0.00140.089560.0002
XML
Image XML parsing0.00100.063630.0003
class_abstraction
Instantiating content class attribute0.00000.001770.0000
General
dbfile0.00090.0572230.0000
String conversion0.00000.000640.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/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
4content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
5content/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: 15
 Number of unique templates used: 6

Time used to render debug report: 0.0001 secs