Create view other for article

Author Message

Alexandre huytq

Friday 28 July 2006 3:16:41 am

You have page layout : header + leftmenu + maincontent + rightmenu + footer
How to when you go to an article in your site, you want to view full article without leftmenu and right menu. Contrary to when you go to an other article, you see full article with leftmenu, rightmenu.
what 's this idea ?
where will you do to edit the code piece ? How are the algorithm ? and it's in what's file?

How can accomplish this ?
Thanks for your help.

Tran Quang Huy

Christian Lundvang

Friday 28 July 2006 5:41:27 am

Hi

There are several ways to do this.

One of them is if you use sections in eZ publish, you can accomplish this.

Add a new pagelayout.tpl under templates, that you call pagelayout_article.tpl

Then put this in your override.ini.append.php

[pagelayout_article]
Source=pagelayout.tpl
MatchFile=pagelayout_article.tpl
Subdir=templates
Match[section]=6

In the pagelayout_article you can remove rightmenu and leftmenu, and then you have a full view of the article.

PS: Just remember to assign the article to the new section.

Sections is controled in Setup->Sections.

--
Best Regards
Christian Lundvang
http://www.nxc.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 18 2025 22:19:32
Script start
Timing: Jan 18 2025 22:19:32
Module start 'layout'
Timing: Jan 18 2025 22:19:32
Module start 'content'
Timing: Jan 18 2025 22:19:32
Module end 'content'
Timing: Jan 18 2025 22:19:32
Script end

Main resources:

Total runtime0.6415 sec
Peak memory usage4,096.0000 KB
Database Queries54

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0060 587.9141152.6250
Module start 'layout' 0.00600.0037 740.539139.4453
Module start 'content' 0.00970.6303 779.9844523.3125
Module end 'content' 0.64000.0014 1,303.29698.1641
Script end 0.6414  1,311.4609 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00360.5540160.0002
Check MTime0.00140.2235160.0001
Mysql Total
Database connection0.00080.122710.0008
Mysqli_queries0.587691.6018540.0109
Looping result0.00050.0856520.0000
Template Total0.605994.420.3029
Template load0.00440.686020.0022
Template processing0.601493.757920.3007
Template load and register function0.00020.027310.0002
states
state_id_array0.00140.225110.0014
state_identifier_array0.00090.146120.0005
Override
Cache load0.00380.5986200.0002
Sytem overhead
Fetch class attribute can translate value0.00070.109420.0004
Fetch class attribute name0.00170.271430.0006
XML
Image XML parsing0.00370.575520.0018
class_abstraction
Instantiating content class attribute0.00000.001330.0000
General
dbfile0.00470.7376160.0003
String conversion0.00000.002040.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
2content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
2content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
4content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
1content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.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: 12
 Number of unique templates used: 7

Time used to render debug report: 0.0001 secs