[Comoblog-commit] modules/mod_postbytopic index.php,NONE,1.1 mod_postbytopic.php,NONE,1.1 mod_postby
Status: Inactive
Brought to you by:
markwallis
|
From: iamdecal <iam...@us...> - 2005-11-28 11:13:26
|
Update of /cvsroot/comoblog/modules/mod_postbytopic In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19872/mod_postbytopic Added Files: index.php mod_postbytopic.php mod_postbytopic.txt Log Message: initial add, mod_postbytopic, builds a select box or list of posts by topic with a count, clicking on a link, takes you to the posts MARK - may need the iis stuff adding --- NEW FILE: mod_postbytopic.php --- <?php if (in_array('mod_postbytopic', $SIDEBAR_MODULES)) $mod_pos = 'sidebar'; else $mod_pos = 'top'; require_once (CFG_BASE_PATH.'/modules/mod_postbytopic/include/mod_postbytopic.inc.php'); $postbytopic_items = mod_postbytopic_list(); if ($postbytopic_items) { $mod_postbytopic_tpl = new XTemplate (CFG_BASE_PATH.'/modules/mod_postbytopic/templates/'.$mod_pos.'/mod_postbytopic.tpl.htm'); if (CFG_POSTBYTOPIC_TOPLINE){ $mod_postbytopic_tpl->assign('CFG_POSTBYTOPIC_TOPLINE', CFG_POSTBYTOPIC_TOPLINE ); } for ($c = 0; $c < count($postbytopic_items); $c++) { if ($c % 2){ $tpl->assign('BGCOLOR', '#ffffff'); }else{ $tpl->assign('BGCOLOR', '#efefef'); } $mod_postbytopic_tpl->assign('ITEM', $postbytopic_items[$c]); $mod_postbytopic_tpl->parse('main.item'); } $mod_postbytopic_tpl->parse('main'); $mod_contents = $mod_postbytopic_tpl->text("main"); } else{ $mod_contents = ''; } ?> --- NEW FILE: mod_postbytopic.txt --- Version RC1 (for easymoblog 0.51) This is a working module, but is released as a Request For Comments, There needs to be a way to allow the module to return a null or 0 id to topic.php so we can see the posts that are not assigned to any topic. While its easy enough to make this change in topic.php, that would leave your code out of sync, so its not something we should address ourselves, I'd rather see Ubik and the team make an *official* change and release let me know if you think of any improvements to this module (and if you have ideas for new ones) iam...@ia... cgi.iamdecal.plus.net --- NEW FILE: index.php --- |