Re: Per-page header selection.
Marko Djukic <[email protected]> Fri, 9 Jan 2004 18:08:52 +0100
| Newsgroups | gmane.comp.horde.giapeto |
|---|---|
| Message-ID | <[email protected]> |
Quoting "Kyrian (List)" <[email protected]>: > The problem is that they use CSS and scripting very heavily on a > per-page basis, and these things have to be at least referenced, if not > included inline in the headers. > > However at the moment, Giapeto only allows for a site-wide header file, > and a single site-wide footer file to be included. not necessarily. you can set individual page templates to pages and they will cascade down to any subpages until another change is set. plus, if you want to get real fancy with your own template tags, look in the horde/config/hooks.php file and insert the _giapeto_hook_settags() function. this gets called at the end of a page load just before fetching the horde_template for rendering the page. this means you can either override any giapeto tags already set or create a bunch of your own custom ones. so you could have in the giapeto/config/templates/pages/pages.html file for example: <link rel="stylesheet" href="<tag:cssfile />" type="text/css"> and in your hooks.php (note off the top of my head so there may be errors!): if (!function_exists('_giapeto_hook_settags')) { function _giapeto_hook_settags(&$template) { global $giapeto, $page; if ($page->getName() == 'products') { $template->set('css', 'products.css'); } else { $template->set('css', 'services.css'); } } } and you can build up your per-page style filtering. > Also, there currently doesn't seem to be any functionality to have a > pre-set template layout (well, layouts), which can be re-used to a > greater or lesser extent, most importantly, a layout that you can call > up in one click for a page, without having to recreate the whole layout > for each individual page. Is this in the works too, etc? it's one thing i'd love to see, would give a lot of flexibility. it's not my priority so i'm not planning to spend any time on it. however, if you can come up with a patch i'll gladly include it into the code. > To clarify(?), if you have a site which, for the most part uses the same > LHS, top, and RHS layout, but the middle panel changes each time, > Giapeto as it stands is going to be a PITA to use because you have to > redo the layout for each individual page (and there would be lots!), > rather than just calling up the basic page format in one click. definately not. if you are planning on running a 100 page site, updating content/layout a lot, single-handedly, then yes. it will be too fiddly and the block layout automatic copying would help a lot. however giapeto came about from a request to have 30-40 people working on a huge site each updating their own smaller caged area. for that it works perfectly. marko -- giapeto mailing list Frequently Asked Questions: http://horde.org/faq/ To unsubscribe, mail: [email protected]