[geeklog-modules] Center block API

geeklog-modules-admin at lists.geeklog.net geeklog-modules-admin at lists.geeklog.net
Sat May 10 09:31:20 EDT 2003


I'd like to propose an extension of the center block API (which currently
only exists in CVS anyway, so changing it now shouldn't affect too many
plugins).

Currently, there is only one call to PLG_showCenterblock() at the
beginning of the center area, i.e. above all the stories. No additional
parameters are passed to that function.

I would like to see some flexibility here, so that the center block can
be placed further down the page (e.g. between the featured and the normal
stories or at the end of the page). Also, it may be of interest to the
block which page we're on and what the current topic is, so that you
could write blocks that only show up on the first page or display
different content for the topic pages.

This is what I have in mind:

    function PLG_showCenterblock ($where = 0, $page = 1, $topic = '')

$where can be 0 = top of page, 1 = after the featured story, 2 = bottom
of page,
$page number, obviously,
$topic = the ID of the current topic or empty = front page

As a demo, I've hacked the forum's center block to only show up after the
featured story. See it at <http://geeklog.info/>.

Comments?

bye, Dirk


-- 
http://www.haun-online.de/
http://mypod.de/




More information about the geeklog-modules mailing list