Breadcrumbs, need different view mode

Author Message

Peter Bailey

Tuesday 01 April 2003 9:20:14 am

I've got my breadcrumbs template snippet working, but for some nodes, I don't want the breadcrumb links to use the "full" view mode.

How can I specify A different view mode in a way that won't be a total pain in the butt? FYI, I've made some of my own view-modes.

Jan Borsodi

Thursday 03 April 2003 3:08:35 am

How are the links built now? Manually or trough other templates?

If it's manually then only have check for those special nodes and specify another view, like:

{section name=Child loop=$children}
{section show=eq($:item.node_id,42)}
{concat("content/view/special_mode/",$:item.node_id)|ezurl}
{section-else}
{concat("content/view/full/",$:item.node_id)|ezurl}
{/section}
{/section}

If it's trough other templates you can add the same check there or use override templates.

--
Amos

Documentation: http://ez.no/ez_publish/documentation
FAQ: http://ez.no/ez_publish/documentation/faq

Peter Bailey

Thursday 03 April 2003 6:38:23 am

Ideally, I would like something like that, but I don't know how to go about doing that using the data from $Path, as each item only seems to have the url and text.

I wanted to create a new template in /design/(mydesign)/override/templates/node/view/ and name it breadcrumb_link.tpl.

Now, when making the breadcrumbs, I wanted to just usd it like this

{section name=Path loop=$module_result.path offset=2 max=-1}
/ {node_view_gui view=breadcrumb_link content_node=$Path:item}
{/section}

Following me? Is there another way to create these breadcrumbs without using $module_result.path? Or does $module_result.path contain more data than I think it does? I looked at the output from this

{$module_result.path|attribute(show())}

And there doesn't seem to be anything else I can use.

Erik Petersen

Tuesday 01 July 2003 3:28:03 pm

Sorry for being off topic but...

Can someone please explain to me where $module_result is documented? What class is it, what are its attributes and what other "global" objects are available to templates? What is $children? Where does it come from in the example above or is the example a snipit? My magic documanation decoder ring must be held up in the mail.

Another question on view modes: why do I not have a /design/standard/templates/node/view/embed.tpl file? I'm using 3.1 but it aint there as the documentation "suggests". I say that because it doesn't say much especially what I would use them for or what they might output.

I've spent 4 days so far farting with ezp3 and so far I'm yet to get a single page to display. The documentation takes me as far as an admin login page and whatever else I've found is either unclear, incomplete or an unanswered forum post.

Excuse my noobie rant but this trial and error approach has become trying. Is there any documentation that will take me from the admin login page to a visible and workable basic site? Anything at all that might help a site admin to get this thing working in any fashion at all or must I continue to search for easter eggs?

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 30 2025 21:11:16
Script start
Timing: Jan 30 2025 21:11:16
Module start 'layout'
Timing: Jan 30 2025 21:11:16
Module start 'content'
Timing: Jan 30 2025 21:11:16
Module end 'content'
Timing: Jan 30 2025 21:11:16
Script end

Main resources:

Total runtime0.0421 sec
Peak memory usage6,144.0000 KB
Database Queries3

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0061 588.1563151.2109
Module start 'layout' 0.00610.0091 739.3672220.6875
Module start 'content' 0.01530.0252 960.05471,001.8047
Module end 'content' 0.04040.0017 1,961.859433.9922
Script end 0.0421  1,995.8516 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00266.1995140.0002
Check MTime0.00102.3771140.0001
Mysql Total
Database connection0.00081.940910.0008
Mysqli_queries0.008119.236030.0027
Looping result0.00000.042410.0000
Template Total0.00123.010.0012
Template load0.00092.246910.0009
Template processing0.00030.692410.0003
Override
Cache load0.00061.390510.0006
General
dbfile0.005312.488980.0007
String conversion0.00000.021540.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 1
 Number of unique templates used: 1

Time used to render debug report: 0.0001 secs