Drake CMS Official Forums - read-only archive

You are reading the Drake CMS Official Forums archive, available for historical purposes only.

Drake CMS has been rebranded into Lanius CMS, visit the new Lanius CMS Official Forums if you need support about Lanius CMS or Drake CMS -> Lanius CMS migration.



Home page Templates > Can I use multiple templates? Permanent link to this page
 
 
Author Message:
hbryant
Can I use multiple templates?
10 May 2007 03:37
Anonymous Hello,

I am in the process of studying the templates supplied with Drake 0.4 Beta in order to create my own. I am downloading the video tutorials and additional templates from sourceforge as I write this.

One snag I have encountered so far is that I cannot find how to assign different templates for different pages. I would like one template (layout) for my splash page and a different template for my other pages. Is there a way to do that?

I am somewhat comfortable writing php4/5 so if someone just points me in the right direction maybe I can customize it myself.

Thanks
 
legolas558
Re : Can I use multiple templates?
10 May 2007 04:18
Anonymous Quote:

Hello,

I am in the process of studying the templates supplied with Drake 0.4 Beta in order to create my own.


You'd better study the SVN versions of the templates since we are in the process of simplifying their CSS

Quote:

One snag I have encountered so far is that I cannot find how to assign different templates for different pages. I would like one template (layout) for my splash page and a different template for my other pages. Is there a way to do that?

As far as I know, no.

With Drake CMS you can assign a different set of CSS classes supplying the CSS class suffix. Example: if you want that the frontpage component inherits uses the set of -splash classes you would have to edit the component instance from the Admin backend -> Menu -> mainmenu -> Home (edit) and specify splash as class suffix.

Then you would have to edit template_css.css and duplicate the classes used by the component adding a -splash suffix to each class name (more documentation coming soon).

But if your need is to have a totally different template for the first page and then another template for the other pages, then this will not possible.

Quote:

I am somewhat comfortable writing php4/5 so if someone just points me in the right direction maybe I can customize it myself.

Thanks


Of course you can "hack" Drake CMS to do what you need: just put a line $d_template='splashtemplate'; in components/com_frontpage/frontpage.php and it should work.

But, as you can see, it is not a clean way to reach the scope wink
Remember that if you edit the core files the automatic online updates will not work as they will first verify the source before being applied (you will have to revert the changes before applying them or else proceed to a manual installation of the next release).

If you need further help, please ask.
 
Top