List of sub-pages

Talk about writing modules and plugins for CMS Made Simple, or about specific core functionality. This board is for PHP programmers that are contributing to CMSMS not for site developers
Post Reply
User avatar
korpirkor
Forum Members
Forum Members
Posts: 100
Joined: Sun Oct 28, 2007 1:15 pm
Location: Poland, Warsaw

List of sub-pages

Post by korpirkor »

Hi !
I want to make a list of subelements of some page (ID=4). It looks like that:
Image

I want to create something like this:

Code: Select all

TITLE    | Page Thumb | Extra3
Kopara      img1.jpg      fffff
Spychacz    img2.jpg      ggg
Could anybody help me with this ?

Thanks,
Korpirkor
[url=http://www.polishwebdesign.pl/]Polish WebDesign Cezary Nowak
Projektowanie stron WWW[/ur]
User avatar
korpirkor
Forum Members
Forum Members
Posts: 100
Joined: Sun Oct 28, 2007 1:15 pm
Location: Poland, Warsaw

Re: List of sub-pages

Post by korpirkor »

Ok. I finished this :)
Menu module is more complex than i thought.

in parent page:

Code: Select all

{menu start_page="nasz-sprzet" template="tabela" show_all="1"}
in template "tabela":

Code: Select all

{if $count > 0}
	<table class="tabela_styl1">
	<tr>
		<td class="td_head">Miniatura</td>
		<td class="td_head">Opis</td>
	</tr>
	{foreach from=$nodelist item=node}
		{if $node->index != 0}
	<tr>
		<td class="komorka_img"><a href="{$node->url}"><img src="uploads/images/{$node->thumbnail}" alt="{$node->menutext}" /></a></td>
		<td class="komorka_opis"><a href="{$node->url}"><h1>{$node->menutext}</h1></a>{$node->extra3}</td>
	</tr>
		{/if}
	{/foreach}
	</table>
{/if}
[url=http://www.polishwebdesign.pl/]Polish WebDesign Cezary Nowak
Projektowanie stron WWW[/ur]
Post Reply

Return to “Developers Discussion”