|
Monday 19 March 2007 7:55:47 am
Survey says ... 'Template Modification' or what is 'Template and or Class Modification'?
This is not a new subject, check through the history,
<i>http://www.google.com/custom?cx=016925729212334848828:gr8yusdgz9g&cof=LH%3A34%3BCX%3AGooZee%3BFORID%3A0%3BS%3Ahttp%3A%2F%2Fgoozee%2Ebenn%2Eorg%2F%3BL%3Ahttp%3A%2F%2Fgoozee%2Ebenn%2Eorg%2Fimages%2Fgoozee%2Epng%3BLP%3A1&q=Sitemap&sa=GooZee+Search&hl=en&client=google-coop-np</i> <i>http://ez.no/content/advancedsearch?&SearchText=sitemap&SubTreeArray%5B%5D=308&SearchDate=-1&SearchPageLimit=5</i>
|
kracker (the)
|
Monday 19 March 2007 8:31:51 am
It did mention, template modification ... what's more to say?
Take a look at how the ezwebin site design extension does it,
<i>extension/ezwebin/design/ezwebin/templates/node/view/sitemap.tpl From: http://ez.no/community/forum/general/site_map_template/re_site_map_template__7</i> <i>//kracker KMK - Zen State</i>
Member since: 2001.07.13 || http://ezpedia.se7enx.com/
|
Softriva .com
|
Monday 19 March 2007 9:50:16 am
I think there a misunderstanding here. The whole thread is about template overriding. My question is that in the whole content structure there is a node that I don't want it to appear in the sitemap. I am using sitemap.tpl and I don't need to override pagelayout.tpl. Am I missing something?
|
kracker (the)
|
Monday 19 March 2007 10:31:39 am
>> I think there a misunderstanding here. The whole thread is about template overriding. I disagree. I hypervisor all your thinking and then some ;) >> My question is that in the whole content structure there is a node that I don't want it to appear in the sitemap. Then you need to edit sittemap.tpl and either add a content object attribute check for a specific attribute includes an 'exclude from menu'. Add this attribute to all your classes, recreate all your content to include this new class attribute set or not set as needed, and clear cache.
Or just write a static exclusion in your template code (lazy thoughts get work done)
{if $node.node_id|ne(42)}
your site menu logic and content ... are you trying yet? {/if} >> I am using sitemap.tpl and I don't need to override pagelayout.tpl. Naturally :) I include my references when possible, that doesn't mean that they always are relevant 100% on your query. >> Am I missing something? Only the adversity to take action on your own ... <i>//kracker KMK - Hustle</i>
Member since: 2001.07.13 || http://ezpedia.se7enx.com/
|
Softriva .com
|
Monday 19 March 2007 12:03:28 pm
Kracker, >>I disagree. I hypervisor all your thinking and then some ;) Yes there is a misunderstanding. This is noticeable from your answer below >><b>Then</b> you need to edit sittemap.tpl and either add a content object attribute check for a specific attribute includes an 'exclude from men.............. >>Naturally :) I include my references when possible, that doesn't mean that they always are relevant 100% on your query Sorry but you threw me off. You referred me to irrelevant post.
>>Only the adversity to take action on your own ... You really don't know. Any how thanks for your answer and please next time if you don't have the relevant answer please don't post it.
|
|
Tuesday 20 March 2007 1:31:03 am
<i>Original: http://svn.ez.no/svn/extensions/ezwebin/trunk/extension/ezwebin/design/ezwebin/templates/node/view/sitemap.tpl</i> Modification: {def $page_limit=10
$col_count=2
$sub_children=0
$children=fetch('content','list',hash('parent_node_id', $node.node_id,
'limit', $page_limit,
'offset', $view_parameters.offset,
'sort_by', $node.sort_array))}
{*
Exclude Item From Menu (Exclude ID/Array)
*}
{def $exclude=42}
<div class="border-box">
<div class="border-tl"><div class="border-tr"><div class="border-tc"></div></div></div>
<div class="border-ml"><div class="border-mr"><div class="border-mc float-break">
<div class="content-view-sitemap">
<div class="attribute-header">
<h1 class="long">{"Site map"|i18n("design/ezwebin/view/sitemap")} {$node.name|wash}</h1>
</div>
<table width="100%" cellspacing="0" cellpadding="4">
<tr>
{foreach $children as $key => $child}
{*
Exclude Item From Menu (Addition)
*}
{if $child.node_id|ne($exclude)}
<td>
<h2><a href={$child.url_alias|ezurl}>{$child.name}</a></h2>
{if $child.class_identifier|eq( 'event_calendar' )}
{set $sub_children=fetch('content','list',hash( 'parent_node_id', $child.node_id,
'limit', $page_limit,
'sort_by', array( 'attribute', false(), 'event/from_time' ) ) )}
{else}
{set $sub_children=fetch('content','list',hash( 'parent_node_id', $child.node_id,
'limit', $page_limit,
'sort_by', $child.sort_array))}
{/if}
<ul>
{foreach $sub_children as $sub_child}
{*
Exclude Item From Menu (Addition)
*}
{if $sub_child.node_id|ne($exclude)}
<li><a href={$sub_child.url_alias|ezurl}>{$sub_child.name}</a></li>
{/if}
{/foreach}
</ul>
</td>
{if ne( $key|mod($col_count), 0 )}
</tr>
<tr>
{/if}
{/if}
{/foreach}
</tr>
</table>
</div>
</div></div></div>
<div class="border-bl"><div class="border-br"><div class="border-bc"></div></div></div>
</div>
|