Loading...
 
Skip to main content

multiple forumlists

Status
Closed
Subject
multiple forumlists
Version
3.x
Category
  • Usability
  • Feature request
  • Patch
Feature
Forum
Resolution status
Invalid
Submitted by
voraistos
Lastmod by
Ushindi Gedeon
Rating
(0)
Description

I want to have multiple forums or (forum_lists) in tikiwiki, because, for example, I want my users to contribute exclusively under the gfdl in one forumlist, but may post copyrighted content in another forumlist.

Current situation: From the menu, the users can click on the forums link which leads them to tiki-forums.php. This displays a list of all the forums the user has the right to see listed, with sections.

The idea is to add an extra argument in the url which specifies which forumlist the user wants to see. example: tiki-forums.php?bigforum=gfdlforum and tiki-forums.php?bigforum=copyrightedstuff
A forum can "belong" to only one "bigforum", or forumlist, so this means an extra column in tiki_forums in the db.

Modifications to tiki-forums.php, right after

Copy to clipboard
// This shows a list of forums everybody can use this listing include_once ("lib/commentslib.php"); $commentslib = new Comments($dbTiki);


I put

Copy to clipboard
// Check for bigforum attribute in url, and assigns it to bigforum variable. If not, display an error page. this means tiki-forums.php displays an error page. if (isset($_REQUEST["bigforum"])) { $bigforum = $_REQUEST["bigforum"]; } else { $smarty->assign('errortype', 401); $smarty->assign('msg', tra("Permission denied you cannot view this page")); $smarty->display("error.tpl"); die; }


And in commentslib.php, in the list_forums function, after

Copy to clipboard
if ( $res['forumId'] != '' && $this->user_has_perm_on_object($user, $res['forumId'], 'forum', 'tiki_p_forum_read') ) {


I put

Copy to clipboard
if ( $bigforum == $res['bigforum'] ){

with an extra closing } somewhere down the road.


The bigforum attribute must be manually added in the db, but appart from that it works. better integration with the rest of Tiki would be awesome, url rewrite could give something like tiki.org/forums/IDorNAMEoftheBigforum/


All of this is just broken hacking and my first attempt at doing something, so don't be too harsh 😉

Solution
Workaround
Importance
5
Priority
25
Demonstrate Bug on Tiki 19+
Demonstrate Bug (older Tiki versions)
Ticket ID
2384
Created
Thursday 26 March, 2009 04:15:29 UTC
by Unknown
LastModif
Monday 25 May, 2026 18:23:44 UTC


Show PHP error messages