How to use delimiter with two lines

Author Message

Leandro Alves

Monday 20 February 2006 11:49:47 am

Hi

I have the following code:

{let  list_items=fetch( content, list, hash( parent_node_id, 2,
                                sort_by, array( priority, true() ),
                                class_filter_type, include,
                                class_filter_array, array( 'folder' ) ) ) }

   <table>
      <tr>
         {section var=child loop=$list_items}
            <td width="300">
               {node_view_gui view=line content_node=$child}<br/>
            </td>
            {delimiter modulo=6}
      </tr>
      <tr>
          {/delimiter}
          {/section}
      </tr>
   </table>
{/let}

With this code I have an output like this:

| line | line | line | line | line | line |

How should I change this code to have an output like this:

| line | line | line | line | line | line |
| line | line | line | line | line | line |

Please, I don't mean just to change {delimiter modulo=6} to {delimiter modulo=2}. I want two line by item.

The code that I would like to make dynamic is this:

<table>
   <tr>
      <td width="300" height="2" valign="top">
         <img src={"line.png"|ezimage}>
      </td>
   </tr>
   <tr>
      <td width="300" height="17" valign="middle">
         item
      </td>
   </tr>
</table>

Thanks in advance!

Leandro

André R.

Monday 20 February 2006 3:07:58 pm

you mean something like this ??

{let list_items=fetch( content, list, hash( parent_node_id, 2, 
                               sort_by, array( priority, true() ), 
                               class_filter_type, include, 
                               class_filter_array, array( 'folder' ) ) ) } 
 
  <table> 
     <tr> 
        {section var=child loop=$list_items} 
           <td width="300"> 
           <table width="100%"> 
              <tr> 
                  <td height="2" valign="top"> 
                      <img src={"line.png"|ezimage}> 
                  </td> 
               </tr> 
              <tr> 
                <td width="300" height="17" valign="middle"> 
                     item 
                 </td> 
               </tr> 
           </table>
           </td> 
           {delimiter modulo=6} 
     </tr> 
     <tr> 
         {/delimiter} 
         {/section} 
     </tr> 
  </table> 
{/let} 

but the:
<td width="300" height="2" valign="top">
<img src={"line.png"|ezimage}>
</td>

seems like would be better to do with some css

 

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

Leandro Alves

Monday 20 February 2006 8:07:42 pm

Hey André,

Thanks a lot for your reply...
It works like a charm!

Cheers,

Leandro

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 19:23:26
Script start
Timing: Jan 18 2025 19:23:26
Module start 'layout'
Timing: Jan 18 2025 19:23:26
Module start 'content'
Timing: Jan 18 2025 19:23:27
Module end 'content'
Timing: Jan 18 2025 19:23:27
Script end

Main resources:

Total runtime1.6146 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.0081 589.1484152.6406
Module start 'layout' 0.00810.0033 741.789139.4609
Module start 'content' 0.01141.6017 781.2500548.7500
Module end 'content' 1.61300.0016 1,330.000012.1563
Script end 1.6146  1,342.1563 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00370.2291160.0002
Check MTime0.00150.0898160.0001
Mysql Total
Database connection0.00190.118310.0019
Mysqli_queries1.554696.2805570.0273
Looping result0.00050.0333550.0000
Template Total1.567197.120.7836
Template load0.00210.130220.0011
Template processing1.565096.926620.7825
Template load and register function0.00020.009610.0002
states
state_id_array0.00220.133210.0022
state_identifier_array0.00170.103320.0008
Override
Cache load0.00180.1102310.0001
Sytem overhead
Fetch class attribute can translate value0.00080.046620.0004
Fetch class attribute name0.00100.060340.0002
XML
Image XML parsing0.00050.032820.0003
class_abstraction
Instantiating content class attribute0.00000.000440.0000
General
dbfile0.00090.0538170.0001
String conversion0.00000.000540.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
9content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
5content/datatype/view/ezxmltags/literal.tpl<No override>extension/community/design/standard/templates/content/datatype/view/ezxmltags/literal.tplEdit templateOverride template
1content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
2content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 22
 Number of unique templates used: 7

Time used to render debug report: 0.0001 secs