Forums / General / Overriding an overrider lol

Overriding an overrider lol

Author Message

David Barker

Tuesday 05 August 2003 11:48:53 am

Hey,
I have got most of my site up and working but there is one thing I want to do. I have about 6 different folders coming off my root folder which each have their own section (and in these folders I put my content)... e.g Info, Products, About Us. But I would like to be able to make it so that when you go to the folder for Info (for example), I can make my own page (not just the listing... but make it as if I have just made my own HTML page). I'm not sure how to explain it.

At the moment, when I go to the Info folder, each folder/content in the Info folder is listed with the 'full' template. But I would like to make my totally own page instead of listing each content like it does now.

I currently have an override for called folder.tpl which is the template for 'full' when viewing a folder and I tried to make another override which overrides when you visit the node for Info (and in this template I put my own content), but it keeps just showing me the list like normal. Is it because I have two overrides for basically the same thing? How can I do this?

Thanks!
Dave

Alex Jones

Tuesday 05 August 2003 1:24:04 pm

Dave, are you actually using a node override for that folder which you want to override? Could you post the part of your override.ini.append so we can look at it?

In the meantime, here is an example of overriding a specific node which is of a class that also has an override associated with it:

[full_steelchart]
Source=node/view/full.tpl
MatchFile=full_steelchart.tpl
Subdir=templates
Match[node]=842

[article]
Source=node/view/full.tpl
MatchFile=article.tpl
Subdir=templates
Match[section]=3

Also, you may want to check the order of your overrides. Put the most specific (node) before the less specific.

Alex

Alex
[ bald_technologist on the IRC channel (irc.freenode.net): #eZpublish ]

<i>When in doubt, clear the cache.</i>

David Barker

Tuesday 05 August 2003 2:52:02 pm

Once again your advice has been great :) I've sorted it.
I was using the template editor thing that is under 'Set Up' in the Admin, and I couldn't see a way to change the order of the overrides so I didn't think it was important about the order but when you said I should look at the order, I changed my override.ini file.
Just curious... why is there no way to change the order in the admin interface?

Oh well - it's fixed! Thanks a lot!!!

Dave

Alex Jones

Wednesday 06 August 2003 8:28:31 am

Glad to hear you have sorted it out! You may want to post the ordering issue as a suggestion for a future revision. :)

Alex
[ bald_technologist on the IRC channel (irc.freenode.net): #eZpublish ]

<i>When in doubt, clear the cache.</i>