Page 1 of 1

Youtubeplayer manage template/categories

Posted: Thu Jan 27, 2011 9:48 am
by mox
Hi,
cmsms 1.9.1
youtubeplayer 1.3

In the first page I show only a list of categories, with this template:

Code: Select all

<h2 class="LevTit">Videos</h2>
<ul style="list-style-type:none;" class="ytcat">
{foreach from=$itemlist item="item"}
<li {if $item->is_selected}class="active"{/if}>{$item->detaillink}
<br />
<a href="{$item->detailurl}"></a>
<br />
</li>
{/foreach}
</ul>
{if $page_pagenumbers}
<div id="pagemenu" style="text-align: center;">
{$page_previous}&nbsp; {$page_showing}/{$page_totalitems} &nbsp;{$page_next}<br/>
{$page_pagenumbers}
</div>
{/if}
Then, when you click on a category, go to a list of video, directly playable, with this template

Code: Select all

<h2 class="LevTit">{$leveltitle}</h2>
<h2 class="CatTit">{$parentobj->name}</h2>

<ul>
{foreach from=$itemlist item="item"}
<li {if $item->is_selected}class="active"{/if}>
<h3>{$item->name}</h3>
<object width="425" height="344"><param name="movie" value="http://www.youtube.com/v/{$item->videoid}?rel=0&fs=1&loop=0"></param><param name="wmode" value="transparent"></param><param name="allowFullScreen" value="true"><embed src="http://www.youtube.com/v/{$item->videoid}?rel=0&fs=1&loop=0" allowfullscreen="true" type="application/x-shockwave-flash" wmode="transparent" width="425" height="344"></embed></object>
<p><span class="lnrosso"> <a href="javascript:javascript:history.go(-1)">Torna all'indice</a></span></p>
<br />
</li>
{/foreach}
</ul>
{if $page_pagenumbers}
<div id="pagemenu" style="text-align: center;">
{$page_previous}&nbsp; {$page_showing}/{$page_totalitems} &nbsp;{$page_next}<br/>
{$page_pagenumbers}
</div>
{/if}
The problem is, I can't figure how have a list of link of categories in the template.
If I use {$parentobj->name} return the name of the current category, but if I want the list of all the categories inside every page of the video list?

Any help is appreciated

Un saluto
Maurizio

Re: Youtubeplayer manage template/categories

Posted: Sat Jan 29, 2011 1:17 am
by mw
why not simply place:
{cms_module module="youtubeplayer"}
at the bottom of your template?