[phpBB] svn: r605 - trunk/phpbb3

taffit at wolffelaar.nl taffit at wolffelaar.nl
Mon Mar 7 00:00:57 CET 2011


Author: taffit
Date: 2011-03-07 00:00:57 +0100 (Mon, 07 Mar 2011)
New Revision: 605

Modified:
   trunk/phpbb3/README.multiboard
   trunk/phpbb3/UPGRADING.Debian
   trunk/phpbb3/config.php
Log:
Use dbname as $url_forum default (actually closes: #599480)

Modified: trunk/phpbb3/README.multiboard
===================================================================
--- trunk/phpbb3/README.multiboard	2011-03-06 23:00:30 UTC (rev 604)
+++ trunk/phpbb3/README.multiboard	2011-03-06 23:00:57 UTC (rev 605)
@@ -28,6 +28,8 @@
 - Copy /usr/share/doc/phpbb3/examples/config.php to a new file in /etc/phpbb3/
   (e.g. /etc/phpbb3/board2.inc.php) and put the the new database credentials
   in it.
+- Eventually configure $url_forum in each configuration file, in order to
+  distinguish the different boards (by default, the database name will be used.
 - Edit /etc/phpbb3/apache.conf and add:
 
 	Alias /board2 /usr/share/phpbb3/www

Modified: trunk/phpbb3/UPGRADING.Debian
===================================================================
--- trunk/phpbb3/UPGRADING.Debian	2011-03-06 23:00:30 UTC (rev 604)
+++ trunk/phpbb3/UPGRADING.Debian	2011-03-06 23:00:57 UTC (rev 605)
@@ -23,19 +23,6 @@
 contains the upstream install/update utilities. However, with these
 you are on your own.
 
-Multiple URL for the same board
-===============================
-
-Due to Debian patch to handle multiboard feature, there are some side
-effects for boards than can be reached by various URL (the cache might not
-be shared, leading to potential misconfiguration or worst, see #599480).
-As a workaround, for such board, you must set url_forum in the config file
-(default /etc/phpbb3/database.inc.php), e.g. $url_forum = 'my.board';
-where 'my.board' is an arbitrary value (copy and paste 'my.board' is fine).
-Of course, you need to use a different url_forum value for each board for
-multiboard configuration, and don't need to bother with that in case your
-forum is available through a single URL.
-
 Upgrade from older major versions
 =================================
 

Modified: trunk/phpbb3/config.php
===================================================================
--- trunk/phpbb3/config.php	2011-03-06 23:00:30 UTC (rev 604)
+++ trunk/phpbb3/config.php	2011-03-06 23:00:57 UTC (rev 605)
@@ -51,13 +51,7 @@
 
 // $url_forum is used inside the patched phpBB code in Debian to
 // ensure a working multisite cache/store/...
+// Use the database name as a default fallback.
 if (empty($url_forum)) {
-    $host = $_SERVER["HTTP_HOST"];
-    $script = $_SERVER["SCRIPT_NAME"];
-    $dir = preg_replace('#/(?:|adm/|install-\w+/|download/)\w+\.php#', '',
-                        $script);
-    $url_forum = preg_replace('/[^a-zA-Z0-9._-]/', '',
-                              @str_replace(array('http://', '/', ':'),
-                                           array(''       , '.', '.'),
-                                           $host.$dir));
+	$url_forum = $dbname;
 }





More information about the phpBB-l mailing list