hide a folder and use it for latest news

Author Message

Ndjientcheu Patrick

Tuesday 27 February 2007 3:56:00 am

hi,
In the content struture of my site,I have the following folders:
- Enterprise
- Products
- Services
- Customers
- News

I want that the "news" item doesn't appear in the main menu, but be used to fill the "latest news" toolbar.

I've tried to hide the "news" folder in the content structure so that it will not appear in the main menu,but this action also prevents this folder to fill the "latest news" toolbar.

Is there another way to achieve this?

Thanks.

Claudia Kosny

Tuesday 27 February 2007 5:12:43 am

Hi

If your customer should never see a full news article, you can set the news folder to hidden and add a 'ignore_visibility' parameter to the fetch function for the latest news.

If your news listing displays just the intro of the news articles so your customer needs to be able to see the full news article, I would just exclude this news folder from the main menu. Easiest way would be to check for the node id in the loop where the menu entries are created. If the node id is the same as the node id of the news folder, don't display anything.

Claudia

Paul Borgermans

Tuesday 27 February 2007 6:12:04 am

You could also clone the folder class and exclude this class from the menu/navigation or even make it so that end-users are not allowed to see objects of this class. Thi sneeds only editing ini files or the roles/policies.

That's what I did for a similar situation in which I had to hide a "container" without preventing read-access to the items below it. In my use-case, editors are seeing this cloned folder objects, regular users not.

hth

Paul

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

Ndjientcheu Patrick

Friday 09 March 2007 8:59:18 am

hi,
thanks for you help.I finally solve my problem.As Claudia suggested to me,I excluded the "news" folder in the loop where menu entries are created. To do his, I just edit the menu.ini.append.php file,in the excluded section:
[Excluded]
Node[]
Node[]=92

where 92 is the number of the "news" node.

Note that i'm using the dynamic top rollover menu.After that,I also edit the file dynamic_double_top_rollover.tpl (<Siteroot>\extension\dynamicdoubletopmenu\design\base\templates\menu) so that it doesn't display excluded items.I just comment lines which did it.

That's all.

Thanks again for your help.

Xavier Dutoit

Saturday 10 March 2007 1:15:58 am

What I do in these cases is to put the news folder in the media

http://www.sydesy.com

paul bolger

Thursday 26 April 2007 11:37:53 pm

Hi Ndjientcheu

I tried your [exclude] method with a flat_left menu and couldn't get it to work. Can you give any more detail?

thanks
Paul Bolger

Paul Bolger

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

Main resources:

Total runtime0.5756 sec
Peak memory usage4,096.0000 KB
Database Queries72

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0051 588.0391152.6406
Module start 'layout' 0.00510.0030 740.679739.4609
Module start 'content' 0.00820.5659 780.1406694.6719
Module end 'content' 0.57410.0015 1,474.812516.1406
Script end 0.5755  1,490.9531 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00310.5369160.0002
Check MTime0.00130.2308160.0001
Mysql Total
Database connection0.00080.133910.0008
Mysqli_queries0.507788.2079720.0071
Looping result0.00070.1252700.0000
Template Total0.547095.020.2735
Template load0.00200.349720.0010
Template processing0.544994.677920.2725
Template load and register function0.00010.020310.0001
states
state_id_array0.00100.174310.0010
state_identifier_array0.00090.150120.0004
Override
Cache load0.00220.3826460.0000
Sytem overhead
Fetch class attribute can translate value0.00050.089550.0001
Fetch class attribute name0.00320.5597100.0003
XML
Image XML parsing0.00210.356950.0004
class_abstraction
Instantiating content class attribute0.00000.0029110.0000
General
dbfile0.00130.2256350.0000
String conversion0.00000.001440.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
5content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
6content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
3content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
7content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 23
 Number of unique templates used: 6

Time used to render debug report: 0.0001 secs