Hallo everybody,
I tried to find an answer with the forum's search but unfortunately I failed.
I designed a website with several content areas (content boxes). The general idea was to seperate different contents which are shown on one page under one general topic. It's difficult to explain, visit http://www.leo-goettingen.de to understand (content is German, but the texts aren't important).
Of course I could create one template with one content box, a second with two content boxes etc. But it would be hard to add or delete a content box if I need to do so. Last but not least my question:
Does CMS made simple support multiple content areas in one template without specifying how much content areas there will be?
Many thanks in advance!
Mamphil
Unlimited number of content boxes
Re: Unlimited number of content boxes
ah, especially the gastebuch where you got spammed is quite instructive
. The M in milf stands for mädchen?
Anyway, back to the point at hand: no I don't think so, as the editpage code detrmines how many content blocks you need based on the template it is assigned to. How could you use more blocks if you cannot enter the content for it in the first place?
If your number of bocks is variable per page, the I thnk it is better place to use put them in the actual content. Just add all contetn in one or two blocks, then open its html and put some s around it. Not very user friendly, but doable.

Anyway, back to the point at hand: no I don't think so, as the editpage code detrmines how many content blocks you need based on the template it is assigned to. How could you use more blocks if you cannot enter the content for it in the first place?
If your number of bocks is variable per page, the I thnk it is better place to use put them in the actual content. Just add all contetn in one or two blocks, then open its html and put some s around it. Not very user friendly, but doable.
Re: Unlimited number of content boxes
Hi!
Thanks for your answer! I got the idea to abuse the news module for this feature. I stripped the summary template (Content -> News -> Summary Template) and inserted my content boxes:
In the original template I "forgot" the {content} area, all the contents can be inserted with the news modul. Of course it would be possible to leave one {content} area and create the additional boxes with the news module.
Regards,
Mamphil
Thanks for your answer! I got the idea to abuse the news module for this feature. I stripped the summary template (Content -> News -> Summary Template) and inserted my content boxes:
Code: Select all
<!-- Start News Display Template -->
{foreach from=$items item=entry}
<div class="box">
<h1>{$entry->title}</h1>
<div>{eval var=$entry->content}</div></div>
{/foreach}
<!-- End News Display Template -->
Regards,
Mamphil
Re: Unlimited number of content boxes
The news module has its own templates, but they do exacly what you just described.
Re: Unlimited number of content boxes
Maybe with other insert content?Mamphil wrote: I designed a website with several content areas (content boxes).
........
Code: Select all
From content help:
{content}
What parameters does it take?
* (optional)block - Allows you to have more than one content block per page. When multiple content tags are put on a template, that number of edit boxes will be displayed when the page is edited.
Re: Unlimited number of content boxes
no, he wanted a variable number of boxes. if you use content you have to define them beforehand. The news module probably fits better here. (like he already implemented)