Configuring sections and applying templates to sections

Configuring sections and applying templates to sections

Wednesday 27 August 2003 3:50:13 pm - 1 reply

Author Message

Willie Seabrook

Wednesday 27 August 2003 7:35:27 pm

Answer #1:

No, all data created through the admin interface is available everywhere. There are two possible reasons why you cannot view any objects of your book class on the site1.

1. Your template is configured incorrectly (are you using fetch correctly, with 'node' function?) Templates are hard to debug but turn debugging on in site.ini. Look at the templates for the class that come with ez.

2. (And this problem has effected me) is that perhaps your viewing as the anonymous user. ezpublish will not tell you by default that access has been denied - it will just not show anything (another annoying thing). Try going to /user/login and entering admin details and then go back and attempt to view your object.

Answer #2:
Find override.ini.append for your new site (this is where templates are assigned) and add something like the following:

#Books
[books]
Source=node/view/full.tpl
MatchFile=my_book_template.tpl
Subdir=templates
Match[class]=14
Match[section]=88

Where 14 is the class id and 88 is the section id. This is telling ez that "if you are showing something in section number 88 and it is of type 14 then use the template my_book_template.tpl that is found in /override/templates."

A section is not really a seperate place on your website its just an "id" that is assigned to a subtree of folders in the site. You do this by first creating a new section and then clicking on the "assign" button, then selecting the top level folder that you want to assign it to.

Yes the documentation sucks, and despite what the ezpublish guys say the community is very small and inactive. Its getting better though. Ezpublish 3 is not as ez as it appears. It does kick serious butt though once you get a hang on it. Check out the wiki I can't remember the url but the google search "ezpublish wiki" finds it.

Regards,
Willie

You must be logged in to post messages in this topic!

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.