Multi column entries layout etc.

Skinning and designing Serendipity (CSS, HTML, Smarty)
Post Reply
Hoshi
Regular
Posts: 8
Joined: Fri May 27, 2005 1:37 pm
Location: Limerick, Ireland
Contact:

Multi column entries layout etc.

Post by Hoshi » Sun Nov 27, 2005 6:14 pm

Hi people. I am currently running wp which is quite nice but the theme design stuff really looks crappy and difficult in comparison to smarty. So I am probably going back to s9y.

So much for the background info. I am planning to create a couple of themes that include the following: a theme that displays only two full articles or excerpts (one post in German and another one in English). Also I'd like to have the latest entries in specific categories summarized in block under those articles etc.

Is it possible to create such a theme using the sub-blog plugin or is there any special smarty code (for example to have position blocks on the bottom of a page).

Did anyone do this before with his s9y blog???

Any help, tips, advice, information appreciated.

Guest

Re: Multi column entries layout etc.

Post by Guest » Sun Nov 27, 2005 7:33 pm

Actually, I haven't seen such a blog yet.

But of course it can be done :) I might be able to give you further clues if you show me a dummy design.

Basically, judebert gave some tips and just recently in nightly builds we improved the API so that it's much easier to do what you want.

You can write a plugin, which can listen to the frontpage and then just use multiple serendipity_printEntries() calls with different parameters to build together the frontpage. The 'genpage' hook is quite suitable for that, and you can set a $serendipity['smarty_raw_mode'] within a templates config.inc.php to control the whole template logic.

In the beginning it might be a bit compilcated to get used to it, but in latest nightlies we have quite a lot of phpdoc comments which could get you started. http://www.s9y.org/40.html also holds a lot of information.

The central files you will want to inspect are index.php, include/genpage.inc.php and the serendipity_fetchEntries / printEntries functions in include/functions_entries.inc.php. All can be used as API method calls within a plugin and/or your templates config.inc.php file.

If you have problems, or after investigating this a bit it is too complicated for you, I am willing of course to help more. With that dummy design, I might even give you a basic template and/or plugin, but that might take me a day or two.

HTH,
Garvin

Hoshi
Regular
Posts: 8
Joined: Fri May 27, 2005 1:37 pm
Location: Limerick, Ireland
Contact:

Post by Hoshi » Sun Nov 27, 2005 7:41 pm

Hi Garv. I'm not that familiar with PHP but I will see what I can come up with. A dummy design is on the way. Thanks for you help.

User avatar
garvinhicking
Core Developer
Posts: 30020
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Post by garvinhicking » Mon Nov 28, 2005 12:32 pm

BTW: I've just committed a new document to http://blog.s9y.org/archives/85-More-Po ... marty.html which might be interesting for you.

Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/

Post Reply