Merge remote-tracking branch 'upstream/develop' into feature/merging-style-components

* upstream/develop: (65 commits)
  [ticket/10730] Added label tag around "select" text in post splitting UI
  [ticket/10732] Add config_dev.php and config_test.php to .gitignore
  [ticket/10586] Added space in if statement
  [ticket/10586] Tidy up comments
  [task/php5.3] Updated range of tested PHP versions
  [task/php5.3] Looks like I missed a few places that needed PHP 5.2 changed to PHP 5.3.2
  [task/php5.3] Changed minimum PHP requirement for Ascraeus to 5.3.2
  [ticket/10723] Stop Travis running all tests on sqlite
  [ticket/10703] Added a condition to check if ext directory exists
  [task/travis] Refactor php version check for dbunit install
  [task/travis] Exclude functional and slow tests
  [ticket/10719] Revert "Skip functional tests on PHP 5.2"
  [task/travis-develop2] Update version from 5.3 to 5.3.2
  [task/travis] Dropping support for 5.2 in develop branch
  [task/travis] Some more small travis fixes
  [task/travis] Rename travis phpunit config files
  [task/travis] Fixing some travis issues
  [ticket/10684] Adjust function and parameter name, minor changes.
  [task/travis] Add automated testing to readme
  [task/travis] Removing development information
  ...

Conflicts:
	phpBB/install/database_update.php
This commit is contained in:
Vjacheslav Trushkin 2012-03-29 22:38:07 +03:00
commit ba431def5d
65 changed files with 766 additions and 97 deletions

2
.gitignore vendored
View file

@ -4,6 +4,8 @@
/phpBB/cache/*.php /phpBB/cache/*.php
/phpBB/cache/queue.php.lock /phpBB/cache/queue.php.lock
/phpBB/config.php /phpBB/config.php
/phpBB/config_dev.php
/phpBB/config_test.php
/phpBB/ext/* /phpBB/ext/*
/phpBB/files/* /phpBB/files/*
/phpBB/images/avatars/gallery/* /phpBB/images/avatars/gallery/*

25
.travis.yml Normal file
View file

@ -0,0 +1,25 @@
language: php
php:
- 5.3.2
- 5.4
env:
- DB=mysql
- DB=postgres
before_script:
- sh -c "if [ '$DB' = 'pgsql' ]; then psql -c 'DROP DATABASE IF EXISTS phpbb_tests;' -U postgres; fi"
- sh -c "if [ '$DB' = 'pgsql' ]; then psql -c 'create database phpbb_tests;' -U postgres; fi"
- sh -c "if [ '$DB' = 'mysql' ]; then mysql -e 'create database IF NOT EXISTS phpbb_tests;'; fi"
- sh -c "if [ '$TRAVIS_PHP_VERSION' = '5.2' ]; then pear install --force phpunit/DbUnit; else pyrus install --force phpunit/DbUnit; fi"
- phpenv rehash
script:
- phpunit --configuration travis/phpunit-$DB-travis.xml
notifications:
email:
recipients:
- dev-team@phpbb.com
on_success: change
on_failure: change

View file

@ -15,6 +15,12 @@ Find support and lots more on [phpBB.com](http://www.phpbb.com)! Discuss the dev
3. [Read our Git Contribution Guidelines](http://wiki.phpbb.com/Git); if you're new to git, also read [the introduction guide](http://wiki.phpbb.com/display/DEV/Working+with+Git) 3. [Read our Git Contribution Guidelines](http://wiki.phpbb.com/Git); if you're new to git, also read [the introduction guide](http://wiki.phpbb.com/display/DEV/Working+with+Git)
4. Send us a pull request 4. Send us a pull request
## AUTOMATED TESTING
We have unit and functional tests in order to prevent regressions. You can view the bamboo continuous integration [here](http://bamboo.phpbb.com) or check our travis build below.
develop - [![Build Status](https://secure.travis-ci.org/phpbb/phpbb3.png?branch=develop)](http://travis-ci.org/phpbb/phpbb3)
develop-olympus - [![Build Status](https://secure.travis-ci.org/phpbb/phpbb3.png?branch=develop-olympus)](http://travis-ci.org/phpbb/phpbb3)
## LICENSE ## LICENSE
[GNU General Public License v2](http://opensource.org/licenses/gpl-2.0.php) [GNU General Public License v2](http://opensource.org/licenses/gpl-2.0.php)

View file

@ -5,7 +5,7 @@
* @copyright (c) 2005 phpBB Group * @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License v2 * @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License v2
* *
* Minimum Requirement: PHP 5.2.0 * Minimum Requirement: PHP 5.3.2
*/ */
/** /**

View file

@ -1528,6 +1528,7 @@ function get_schema_struct()
'report_closed' => array('BOOL', 0), 'report_closed' => array('BOOL', 0),
'report_time' => array('TIMESTAMP', 0), 'report_time' => array('TIMESTAMP', 0),
'report_text' => array('MTEXT_UNI', ''), 'report_text' => array('MTEXT_UNI', ''),
'reported_post_text' => array('MTEXT_UNI', ''),
), ),
'PRIMARY_KEY' => 'report_id', 'PRIMARY_KEY' => 'report_id',
'KEYS' => array( 'KEYS' => array(

View file

@ -35,7 +35,6 @@ $search_errors = array();
$search = new $class_name($search_errors); $search = new $class_name($search_errors);
$batch_size = isset($argv[2]) ? $argv[2] : 2000; $batch_size = isset($argv[2]) ? $argv[2] : 2000;
$time = time();
if (method_exists($search, 'create_index')) if (method_exists($search, 'create_index'))
{ {
@ -67,6 +66,7 @@ else
while ($post_counter <= $max_post_id) while ($post_counter <= $max_post_id)
{ {
$row_count = 0; $row_count = 0;
$time = time();
printf("Processing posts with %d <= post_id <= %d\n", printf("Processing posts with %d <= post_id <= %d\n",
$post_counter + 1, $post_counter + 1,

View file

@ -37,6 +37,13 @@ function list_extensions()
global $phpbb_extension_manager; global $phpbb_extension_manager;
$phpbb_extension_manager->load_extensions(); $phpbb_extension_manager->load_extensions();
$all = array_keys($phpbb_extension_manager->all_available());
if (empty($all))
{
echo "There were no extensions found.\n";
exit(3);
}
echo "Enabled:\n"; echo "Enabled:\n";
$enabled = array_keys($phpbb_extension_manager->all_enabled()); $enabled = array_keys($phpbb_extension_manager->all_enabled());
@ -49,7 +56,6 @@ function list_extensions()
echo "\n"; echo "\n";
echo "Available:\n"; echo "Available:\n";
$all = array_keys($phpbb_extension_manager->all_available());
$purged = array_diff($all, $enabled, $disabled); $purged = array_diff($all, $enabled, $disabled);
print_extensions($purged); print_extensions($purged);
} }

View file

@ -138,7 +138,7 @@
<li>Oracle</li> <li>Oracle</li>
</ul> </ul>
</li> </li>
<li><strong>PHP 5.2.0+</strong> with support for the database you intend to use.</li> <li><strong>PHP 5.3.2+</strong> with support for the database you intend to use.</li>
<li>getimagesize() function need to be enabled.</li> <li>getimagesize() function need to be enabled.</li>
<li>These optional presence of the following modules within PHP will provide access to additional features, but they are not required. <li>These optional presence of the following modules within PHP will provide access to additional features, but they are not required.
<ul> <ul>

View file

@ -306,11 +306,11 @@
<div class="content"> <div class="content">
<p>phpBB is no longer supported on PHP4 due to several compatibility issues and we recommend that you upgrade to the latest stable release of PHP5 to run phpBB. The minimum version required is PHP 5.2.0.</p> <p>phpBB is no longer supported on PHP4 due to several compatibility issues and we recommend that you upgrade to the latest stable release of PHP5 to run phpBB. The minimum version required is PHP 5.3.2.</p>
<p>Please remember that running any application on a developmental version of PHP can lead to strange/unexpected results which may appear to be bugs in the application (which may not be true). Therefore we recommend you upgrade to the newest stable version of PHP before running phpBB3. If you are running a developmental version of PHP please check any bugs you find on a system running a stable release before submitting.</p> <p>Please remember that running any application on a developmental version of PHP can lead to strange/unexpected results which may appear to be bugs in the application (which may not be true). Therefore we recommend you upgrade to the newest stable version of PHP before running phpBB3. If you are running a developmental version of PHP please check any bugs you find on a system running a stable release before submitting.</p>
<p>This board has been developed and tested under Linux and Windows (amongst others) running Apache using MySQL 3.23, 4.x, 5.x, MSSQL Server 2000, PostgreSQL 7.x, Oracle 8, SQLite and Firebird. Versions of PHP used range from 5.2.0 to 5.3.x without problem.</p> <p>This board has been developed and tested under Linux and Windows (amongst others) running Apache using MySQL 3.23, 4.x, 5.x, MSSQL Server 2000, PostgreSQL 7.x, Oracle 8, SQLite and Firebird. Versions of PHP used range from 5.3.2 to 5.4.x without problem.</p>
<a name="phpsec"></a><h3>7.i. Notice on PHP security issues</h3> <a name="phpsec"></a><h3>7.i. Notice on PHP security issues</h3>

View file

@ -2348,7 +2348,7 @@ if (utf8_case_fold_nfc($string1) == utf8_case_fold_nfc($string2))
<div class="codebox"><pre> <div class="codebox"><pre>
... ...
'FOO_BAR' =&gt; 'PHP version &lt; 5.2.0.&lt;br /&gt; 'FOO_BAR' =&gt; 'PHP version &lt; 5.3.2.&lt;br /&gt;
Visit &quot;Downloads&quot; at &lt;a href=&quot;http://www.php.net/&quot;&gt;www.php.net&lt;/a&gt;.', Visit &quot;Downloads&quot; at &lt;a href=&quot;http://www.php.net/&quot;&gt;www.php.net&lt;/a&gt;.',
... ...
</pre></div> </pre></div>
@ -2357,7 +2357,7 @@ if (utf8_case_fold_nfc($string1) == utf8_case_fold_nfc($string2))
<div class="codebox"><pre> <div class="codebox"><pre>
... ...
'FOO_BAR' =&gt; 'PHP version &amp;lt; 5.2.0.&lt;br /&gt; 'FOO_BAR' =&gt; 'PHP version &amp;lt; 5.3.2.&lt;br /&gt;
Visit &amp;quot;Downloads&amp;quot; at &lt;a href=&quot;http://www.php.net/&quot;&gt;www.php.net&lt;/a&gt;.', Visit &amp;quot;Downloads&amp;quot; at &lt;a href=&quot;http://www.php.net/&quot;&gt;www.php.net&lt;/a&gt;.',
... ...
</pre></div> </pre></div>
@ -2366,7 +2366,7 @@ if (utf8_case_fold_nfc($string1) == utf8_case_fold_nfc($string2))
<div class="codebox"><pre> <div class="codebox"><pre>
... ...
'FOO_BAR' =&gt; 'PHP version &amp;lt; 5.2.0.&lt;br /&gt; 'FOO_BAR' =&gt; 'PHP version &amp;lt; 5.3.2.&lt;br /&gt;
Visit &ldquo;Downloads&rdquo; at &lt;a href=&quot;http://www.php.net/&quot;&gt;www.php.net&lt;/a&gt;.', Visit &ldquo;Downloads&rdquo; at &lt;a href=&quot;http://www.php.net/&quot;&gt;www.php.net&lt;/a&gt;.',
... ...
</pre></div> </pre></div>

View file

@ -397,11 +397,11 @@ class acp_main
// Version check // Version check
$user->add_lang('install'); $user->add_lang('install');
if ($auth->acl_get('a_server') && version_compare(PHP_VERSION, '5.2.0', '<')) if ($auth->acl_get('a_server') && version_compare(PHP_VERSION, '5.3.2', '<'))
{ {
$template->assign_vars(array( $template->assign_vars(array(
'S_PHP_VERSION_OLD' => true, 'S_PHP_VERSION_OLD' => true,
'L_PHP_VERSION_OLD' => sprintf($user->lang['PHP_VERSION_OLD'], '<a href="http://www.phpbb.com/community/viewtopic.php?f=14&amp;t=1958605">', '</a>'), 'L_PHP_VERSION_OLD' => sprintf($user->lang['PHP_VERSION_OLD'], '<a href="http://www.phpbb.com/community/viewtopic.php?f=14&amp;t=2152375">', '</a>'),
)); ));
} }

View file

@ -128,7 +128,7 @@ class acp_users
$dropdown_modes = array(); $dropdown_modes = array();
while ($row = $db->sql_fetchrow($result)) while ($row = $db->sql_fetchrow($result))
{ {
if (!$this->p_master->module_auth($row['module_auth'])) if (!$this->p_master->module_auth_self($row['module_auth']))
{ {
continue; continue;
} }

View file

@ -0,0 +1,31 @@
<?php
/**
*
* @package extension
* @copyright (c) 2011 phpBB Group
* @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License v2
*
*/
/**
* @ignore
*/
if (!defined('IN_PHPBB'))
{
exit;
}
/**
* The interface that extension classes have to implement to run front pages
*
* @package extension
*/
interface phpbb_extension_controller_interface
{
/**
* handle the request to display a page from an extension
*
* @return null
*/
public function handle();
}

View file

@ -352,6 +352,10 @@ class phpbb_extension_manager
public function all_available() public function all_available()
{ {
$available = array(); $available = array();
if (!is_dir($this->phpbb_root_path . 'ext/'))
{
return $available;
}
$iterator = new RecursiveIteratorIterator( $iterator = new RecursiveIteratorIterator(
new RecursiveDirectoryIterator($this->phpbb_root_path . 'ext/'), new RecursiveDirectoryIterator($this->phpbb_root_path . 'ext/'),
@ -428,6 +432,28 @@ class phpbb_extension_manager
} }
return $disabled; return $disabled;
} }
/**
* Check to see if a given extension is available on the filesystem
*
* @param string $name Extension name to check NOTE: Can be user input
* @return bool Depending on whether or not the extension is available
*/
public function available($name)
{
return file_exists($this->get_extension_path($name, true));
}
/**
* Check to see if a given extension is enabled
*
* @param string $name Extension name to check
* @return bool Depending on whether or not the extension is enabled
*/
public function enabled($name)
{
return isset($this->extensions[$name]) && $this->extensions[$name]['ext_active'];
}
/** /**
* Instantiates a phpbb_extension_finder. * Instantiates a phpbb_extension_finder.

View file

@ -128,7 +128,7 @@ class p_master
foreach ($this->module_cache['modules'] as $key => $row) foreach ($this->module_cache['modules'] as $key => $row)
{ {
// Not allowed to view module? // Not allowed to view module?
if (!$this->module_auth($row['module_auth'])) if (!$this->module_auth_self($row['module_auth']))
{ {
unset($this->module_cache['modules'][$key]); unset($this->module_cache['modules'][$key]);
continue; continue;
@ -315,9 +315,23 @@ class p_master
} }
/** /**
* Check module authorisation * Check module authorisation.
*
* This is a non-static version that uses $this->acl_forum_id
* for the forum id.
*/ */
function module_auth($module_auth, $forum_id = false) function module_auth_self($module_auth)
{
return self::module_auth($module_auth, $this->acl_forum_id);
}
/**
* Check module authorisation.
*
* This is a static version, it must be given $forum_id.
* See also module_auth_self.
*/
static function module_auth($module_auth, $forum_id)
{ {
global $auth, $config; global $auth, $config;
global $request; global $request;
@ -362,11 +376,9 @@ class p_master
$module_auth = implode(' ', $tokens); $module_auth = implode(' ', $tokens);
// Make sure $id seperation is working fine // Make sure $id separation is working fine
$module_auth = str_replace(' , ', ',', $module_auth); $module_auth = str_replace(' , ', ',', $module_auth);
$forum_id = ($forum_id === false) ? $this->acl_forum_id : $forum_id;
$is_auth = false; $is_auth = false;
eval('$is_auth = (int) (' . preg_replace(array('#acl_([a-z0-9_]+)(,\$id)?#', '#\$id#', '#aclf_([a-z0-9_]+)#', '#cfg_([a-z0-9_]+)#', '#request_([a-zA-Z0-9_]+)#'), array('(int) $auth->acl_get(\'\\1\'\\2)', '(int) $forum_id', '(int) $auth->acl_getf_global(\'\\1\')', '(int) $config[\'\\1\']', '$request->variable(\'\\1\', false)'), $module_auth) . ');'); eval('$is_auth = (int) (' . preg_replace(array('#acl_([a-z0-9_]+)(,\$id)?#', '#\$id#', '#aclf_([a-z0-9_]+)#', '#cfg_([a-z0-9_]+)#', '#request_([a-zA-Z0-9_]+)#'), array('(int) $auth->acl_get(\'\\1\'\\2)', '(int) $forum_id', '(int) $auth->acl_getf_global(\'\\1\')', '(int) $config[\'\\1\']', '$request->variable(\'\\1\', false)'), $module_auth) . ');');

View file

@ -1180,36 +1180,32 @@ function user_notification($mode, $subject, $topic_title, $forum_name, $forum_id
$topic_title = ($topic_notification) ? $topic_title : $subject; $topic_title = ($topic_notification) ? $topic_title : $subject;
$topic_title = censor_text($topic_title); $topic_title = censor_text($topic_title);
// Get banned User ID's // Exclude guests, current user and banned users from notifications
$sql = 'SELECT ban_userid if (!function_exists('phpbb_get_banned_user_ids'))
FROM ' . BANLIST_TABLE . '
WHERE ban_userid <> 0
AND ban_exclude <> 1';
$result = $db->sql_query($sql);
$sql_ignore_users = ANONYMOUS . ', ' . $user->data['user_id'];
while ($row = $db->sql_fetchrow($result))
{ {
$sql_ignore_users .= ', ' . (int) $row['ban_userid']; include($phpbb_root_path . 'includes/functions_user.' . $phpEx);
} }
$db->sql_freeresult($result); $sql_ignore_users = phpbb_get_banned_user_ids();
$sql_ignore_users[ANONYMOUS] = ANONYMOUS;
$sql_ignore_users[$user->data['user_id']] = $user->data['user_id'];
$notify_rows = array(); $notify_rows = array();
// -- get forum_userids || topic_userids // -- get forum_userids || topic_userids
$sql = 'SELECT u.user_id, u.username, u.user_email, u.user_lang, u.user_notify_type, u.user_jabber $sql = 'SELECT u.user_id, u.username, u.user_email, u.user_lang, u.user_notify_type, u.user_jabber
FROM ' . (($topic_notification) ? TOPICS_WATCH_TABLE : FORUMS_WATCH_TABLE) . ' w, ' . USERS_TABLE . ' u FROM ' . (($topic_notification) ? TOPICS_WATCH_TABLE : FORUMS_WATCH_TABLE) . ' w, ' . USERS_TABLE . ' u
WHERE w.' . (($topic_notification) ? 'topic_id' : 'forum_id') . ' = ' . (($topic_notification) ? $topic_id : $forum_id) . " WHERE w.' . (($topic_notification) ? 'topic_id' : 'forum_id') . ' = ' . (($topic_notification) ? $topic_id : $forum_id) . '
AND w.user_id NOT IN ($sql_ignore_users) AND ' . $db->sql_in_set('w.user_id', $sql_ignore_users, true) . '
AND w.notify_status = " . NOTIFY_YES . ' AND w.notify_status = ' . NOTIFY_YES . '
AND u.user_type IN (' . USER_NORMAL . ', ' . USER_FOUNDER . ') AND u.user_type IN (' . USER_NORMAL . ', ' . USER_FOUNDER . ')
AND u.user_id = w.user_id'; AND u.user_id = w.user_id';
$result = $db->sql_query($sql); $result = $db->sql_query($sql);
while ($row = $db->sql_fetchrow($result)) while ($row = $db->sql_fetchrow($result))
{ {
$notify_rows[$row['user_id']] = array( $notify_user_id = (int) $row['user_id'];
'user_id' => $row['user_id'], $notify_rows[$notify_user_id] = array(
'user_id' => $notify_user_id,
'username' => $row['username'], 'username' => $row['username'],
'user_email' => $row['user_email'], 'user_email' => $row['user_email'],
'user_jabber' => $row['user_jabber'], 'user_jabber' => $row['user_jabber'],
@ -1219,30 +1215,29 @@ function user_notification($mode, $subject, $topic_title, $forum_name, $forum_id
'method' => $row['user_notify_type'], 'method' => $row['user_notify_type'],
'allowed' => false 'allowed' => false
); );
// Add users who have been already notified to ignore list
$sql_ignore_users[$notify_user_id] = $notify_user_id;
} }
$db->sql_freeresult($result); $db->sql_freeresult($result);
// forum notification is sent to those not already receiving topic notifications // forum notification is sent to those not already receiving topic notifications
if ($topic_notification) if ($topic_notification)
{ {
if (sizeof($notify_rows))
{
$sql_ignore_users .= ', ' . implode(', ', array_keys($notify_rows));
}
$sql = 'SELECT u.user_id, u.username, u.user_email, u.user_lang, u.user_notify_type, u.user_jabber $sql = 'SELECT u.user_id, u.username, u.user_email, u.user_lang, u.user_notify_type, u.user_jabber
FROM ' . FORUMS_WATCH_TABLE . ' fw, ' . USERS_TABLE . " u FROM ' . FORUMS_WATCH_TABLE . ' fw, ' . USERS_TABLE . " u
WHERE fw.forum_id = $forum_id WHERE fw.forum_id = $forum_id
AND fw.user_id NOT IN ($sql_ignore_users) AND " . $db->sql_in_set('fw.user_id', $sql_ignore_users, true) . '
AND fw.notify_status = " . NOTIFY_YES . ' AND fw.notify_status = ' . NOTIFY_YES . '
AND u.user_type IN (' . USER_NORMAL . ', ' . USER_FOUNDER . ') AND u.user_type IN (' . USER_NORMAL . ', ' . USER_FOUNDER . ')
AND u.user_id = fw.user_id'; AND u.user_id = fw.user_id';
$result = $db->sql_query($sql); $result = $db->sql_query($sql);
while ($row = $db->sql_fetchrow($result)) while ($row = $db->sql_fetchrow($result))
{ {
$notify_rows[$row['user_id']] = array( $notify_user_id = (int) $row['user_id'];
'user_id' => $row['user_id'], $notify_rows[$notify_user_id] = array(
'user_id' => $notify_user_id,
'username' => $row['username'], 'username' => $row['username'],
'user_email' => $row['user_email'], 'user_email' => $row['user_email'],
'user_jabber' => $row['user_jabber'], 'user_jabber' => $row['user_jabber'],
@ -1273,7 +1268,6 @@ function user_notification($mode, $subject, $topic_title, $forum_name, $forum_id
} }
} }
// Now, we have to do a little step before really sending, we need to distinguish our users a little bit. ;) // Now, we have to do a little step before really sending, we need to distinguish our users a little bit. ;)
$msg_users = $delete_ids = $update_notification = array(); $msg_users = $delete_ids = $update_notification = array();
foreach ($notify_rows as $user_id => $row) foreach ($notify_rows as $user_id => $row)

View file

@ -1666,6 +1666,7 @@ function pm_notification($mode, $author, $recipients, $subject, $message, $msg_i
$subject = censor_text($subject); $subject = censor_text($subject);
// Exclude guests, current user and banned users from notifications
unset($recipients[ANONYMOUS], $recipients[$user->data['user_id']]); unset($recipients[ANONYMOUS], $recipients[$user->data['user_id']]);
if (!sizeof($recipients)) if (!sizeof($recipients))
@ -1673,18 +1674,12 @@ function pm_notification($mode, $author, $recipients, $subject, $message, $msg_i
return; return;
} }
// Get banned User ID's if (!function_exists('phpbb_get_banned_user_ids'))
$sql = 'SELECT ban_userid
FROM ' . BANLIST_TABLE . '
WHERE ' . $db->sql_in_set('ban_userid', array_map('intval', array_keys($recipients))) . '
AND ban_exclude = 0';
$result = $db->sql_query($sql);
while ($row = $db->sql_fetchrow($result))
{ {
unset($recipients[$row['ban_userid']]); include($phpbb_root_path . 'includes/functions_user.' . $phpEx);
} }
$db->sql_freeresult($result); $banned_users = phpbb_get_banned_user_ids(array_keys($recipients));
$recipients = array_diff(array_keys($recipients), $banned_users);
if (!sizeof($recipients)) if (!sizeof($recipients))
{ {
@ -1693,7 +1688,7 @@ function pm_notification($mode, $author, $recipients, $subject, $message, $msg_i
$sql = 'SELECT user_id, username, user_email, user_lang, user_notify_pm, user_notify_type, user_jabber $sql = 'SELECT user_id, username, user_email, user_lang, user_notify_pm, user_notify_type, user_jabber
FROM ' . USERS_TABLE . ' FROM ' . USERS_TABLE . '
WHERE ' . $db->sql_in_set('user_id', array_map('intval', array_keys($recipients))); WHERE ' . $db->sql_in_set('user_id', $recipients);
$result = $db->sql_query($sql); $result = $db->sql_query($sql);
$msg_list_ary = array(); $msg_list_ary = array();

View file

@ -3691,3 +3691,36 @@ function remove_newly_registered($user_id, $user_data = false)
return $user_data['group_id']; return $user_data['group_id'];
} }
/**
* Gets user ids of currently banned registered users.
*
* @param array $user_ids Array of users' ids to check for banning,
* leave empty to get complete list of banned ids
* @return array Array of banned users' ids if any, empty array otherwise
*/
function phpbb_get_banned_user_ids($user_ids = array())
{
global $db;
$sql_user_ids = (!empty($user_ids)) ? $db->sql_in_set('ban_userid', $user_ids) : 'ban_userid <> 0';
// Get banned User ID's
// Ignore stale bans which were not wiped yet
$banned_ids_list = array();
$sql = 'SELECT ban_userid
FROM ' . BANLIST_TABLE . "
WHERE $sql_user_ids
AND ban_exclude <> 1
AND (ban_end > " . time() . '
OR ban_end = 0)';
$result = $db->sql_query($sql);
while ($row = $db->sql_fetchrow($result))
{
$user_id = (int) $row['ban_userid'];
$banned_ids_list[$user_id] = $user_id;
}
$db->sql_freeresult($result);
return $banned_ids_list;
}

View file

@ -71,7 +71,7 @@ class mcp_reports
// closed reports are accessed by report id // closed reports are accessed by report id
$report_id = request_var('r', 0); $report_id = request_var('r', 0);
$sql = 'SELECT r.post_id, r.user_id, r.report_id, r.report_closed, report_time, r.report_text, rr.reason_title, rr.reason_description, u.username, u.username_clean, u.user_colour $sql = 'SELECT r.post_id, r.user_id, r.report_id, r.report_closed, report_time, r.report_text, r.reported_post_text, rr.reason_title, rr.reason_description, u.username, u.username_clean, u.user_colour
FROM ' . REPORTS_TABLE . ' r, ' . REPORTS_REASONS_TABLE . ' rr, ' . USERS_TABLE . ' u FROM ' . REPORTS_TABLE . ' r, ' . REPORTS_REASONS_TABLE . ' rr, ' . USERS_TABLE . ' u
WHERE ' . (($report_id) ? 'r.report_id = ' . $report_id : "r.post_id = $post_id") . ' WHERE ' . (($report_id) ? 'r.report_id = ' . $report_id : "r.post_id = $post_id") . '
AND rr.reason_id = r.reason_id AND rr.reason_id = r.reason_id
@ -116,8 +116,9 @@ class mcp_reports
$template->assign_vars(array( $template->assign_vars(array(
'S_TOPIC_REVIEW' => true, 'S_TOPIC_REVIEW' => true,
'S_BBCODE_ALLOWED' => $post_info['enable_bbcode'], 'S_BBCODE_ALLOWED' => $post_info['enable_bbcode'],
'TOPIC_TITLE' => $post_info['topic_title']) 'TOPIC_TITLE' => $post_info['topic_title'],
); 'REPORTED_POST_ID' => $post_id,
));
} }
$topic_tracking_info = $extensions = $attachments = array(); $topic_tracking_info = $extensions = $attachments = array();
@ -226,7 +227,7 @@ class mcp_reports
'REPORTER_NAME' => get_username_string('username', $report['user_id'], $report['username'], $report['user_colour']), 'REPORTER_NAME' => get_username_string('username', $report['user_id'], $report['username'], $report['user_colour']),
'U_VIEW_REPORTER_PROFILE' => get_username_string('profile', $report['user_id'], $report['username'], $report['user_colour']), 'U_VIEW_REPORTER_PROFILE' => get_username_string('profile', $report['user_id'], $report['username'], $report['user_colour']),
'POST_PREVIEW' => $message, 'POST_PREVIEW' => bbcode_nl2br($report['reported_post_text']),
'POST_SUBJECT' => ($post_info['post_subject']) ? $post_info['post_subject'] : $user->lang['NO_SUBJECT'], 'POST_SUBJECT' => ($post_info['post_subject']) ? $post_info['post_subject'] : $user->lang['NO_SUBJECT'],
'POST_DATE' => $user->format_date($post_info['post_time']), 'POST_DATE' => $user->format_date($post_info['post_time']),
'POST_IP' => $post_info['poster_ip'], 'POST_IP' => $post_info['poster_ip'],

View file

@ -49,6 +49,16 @@ function mcp_topic_view($id, $mode, $action)
$submitted_id_list = request_var('post_ids', array(0)); $submitted_id_list = request_var('post_ids', array(0));
$checked_ids = $post_id_list = request_var('post_id_list', array(0)); $checked_ids = $post_id_list = request_var('post_id_list', array(0));
// Resync Topic?
if ($action == 'resync')
{
if (!function_exists('mcp_resync_topics'))
{
include($phpbb_root_path . 'includes/mcp/mcp_forum.' . $phpEx);
}
mcp_resync_topics(array($topic_id));
}
// Split Topic? // Split Topic?
if ($action == 'split_all' || $action == 'split_beyond') if ($action == 'split_all' || $action == 'split_beyond')
{ {
@ -319,6 +329,7 @@ function mcp_topic_view($id, $mode, $action)
'S_CAN_APPROVE' => ($has_unapproved_posts && $auth->acl_get('m_approve', $topic_info['forum_id'])) ? true : false, 'S_CAN_APPROVE' => ($has_unapproved_posts && $auth->acl_get('m_approve', $topic_info['forum_id'])) ? true : false,
'S_CAN_LOCK' => ($auth->acl_get('m_lock', $topic_info['forum_id'])) ? true : false, 'S_CAN_LOCK' => ($auth->acl_get('m_lock', $topic_info['forum_id'])) ? true : false,
'S_CAN_REPORT' => ($auth->acl_get('m_report', $topic_info['forum_id'])) ? true : false, 'S_CAN_REPORT' => ($auth->acl_get('m_report', $topic_info['forum_id'])) ? true : false,
'S_CAN_SYNC' => $auth->acl_get('m_', $topic_info['forum_id']),
'S_REPORT_VIEW' => ($action == 'reports') ? true : false, 'S_REPORT_VIEW' => ($action == 'reports') ? true : false,
'S_MERGE_VIEW' => ($action == 'merge') ? true : false, 'S_MERGE_VIEW' => ($action == 'merge') ? true : false,
'S_SPLIT_VIEW' => ($action == 'split') ? true : false, 'S_SPLIT_VIEW' => ($action == 'split') ? true : false,

View file

@ -19,7 +19,8 @@ if (!defined('E_DEPRECATED'))
{ {
define('E_DEPRECATED', 8192); define('E_DEPRECATED', 8192);
} }
error_reporting(E_ALL & ~E_NOTICE & ~E_DEPRECATED); $level = E_ALL & ~E_NOTICE & ~E_DEPRECATED;
error_reporting($level);
/* /*
* Remove variables created by register_globals from the global scope * Remove variables created by register_globals from the global scope

View file

@ -24,6 +24,39 @@ $user->session_begin();
$auth->acl($user->data); $auth->acl($user->data);
$user->setup('viewforum'); $user->setup('viewforum');
// Handle the display of extension front pages
if ($ext = $request->variable('ext', ''))
{
$class = 'phpbb_ext_' . str_replace('/', '_', $ext) . '_controller';
if (!$phpbb_extension_manager->available($ext))
{
send_status_line(404, 'Not Found');
trigger_error($user->lang('EXTENSION_DOES_NOT_EXIST', $ext));
}
else if (!$phpbb_extension_manager->enabled($ext))
{
send_status_line(404, 'Not Found');
trigger_error($user->lang('EXTENSION_DISABLED', $ext));
}
else if (!class_exists($class))
{
send_status_line(404, 'Not Found');
trigger_error($user->lang('EXTENSION_CONTROLLER_MISSING', $ext));
}
$controller = new $class;
if (!($controller instanceof phpbb_extension_controller_interface))
{
send_status_line(500, 'Internal Server Error');
trigger_error($user->lang('EXTENSION_CLASS_WRONG_TYPE', $class));
}
$controller->handle();
exit_handler();
}
display_forums('', $config['load_moderators']); display_forums('', $config['load_moderators']);
$order_legend = ($config['legend_sort_groupname']) ? 'group_name' : 'group_legend'; $order_legend = ($config['legend_sort_groupname']) ? 'group_name' : 'group_legend';

View file

@ -1094,6 +1094,9 @@ function database_update_info()
'style_parent_id' => array('UINT:4', 0), 'style_parent_id' => array('UINT:4', 0),
'style_parent_tree' => array('TEXT', ''), 'style_parent_tree' => array('TEXT', ''),
), ),
REPORTS_TABLE => array(
'reported_post_text' => array('MTEXT_UNI', ''),
),
), ),
'change_columns' => array( 'change_columns' => array(
GROUPS_TABLE => array( GROUPS_TABLE => array(

View file

@ -17,9 +17,9 @@ define('IN_INSTALL', true);
$phpbb_root_path = (defined('PHPBB_ROOT_PATH')) ? PHPBB_ROOT_PATH : './../'; $phpbb_root_path = (defined('PHPBB_ROOT_PATH')) ? PHPBB_ROOT_PATH : './../';
$phpEx = substr(strrchr(__FILE__, '.'), 1); $phpEx = substr(strrchr(__FILE__, '.'), 1);
if (version_compare(PHP_VERSION, '5.2.0') < 0) if (version_compare(PHP_VERSION, '5.3.2') < 0)
{ {
die('You are running an unsupported PHP version. Please upgrade to PHP 5.2.0 or higher before trying to install phpBB 3.1'); die('You are running an unsupported PHP version. Please upgrade to PHP 5.3.2 or higher before trying to install phpBB 3.1');
} }
function phpbb_require_updated($path, $optional = false) function phpbb_require_updated($path, $optional = false)

View file

@ -140,7 +140,7 @@ class install_install extends module
// Test the minimum PHP version // Test the minimum PHP version
$php_version = PHP_VERSION; $php_version = PHP_VERSION;
if (version_compare($php_version, '5.2.0') < 0) if (version_compare($php_version, '5.3.2') < 0)
{ {
$result = '<strong style="color:red">' . $lang['NO'] . '</strong>'; $result = '<strong style="color:red">' . $lang['NO'] . '</strong>';
} }

View file

@ -909,7 +909,8 @@ CREATE TABLE phpbb_reports (
user_notify INTEGER DEFAULT 0 NOT NULL, user_notify INTEGER DEFAULT 0 NOT NULL,
report_closed INTEGER DEFAULT 0 NOT NULL, report_closed INTEGER DEFAULT 0 NOT NULL,
report_time INTEGER DEFAULT 0 NOT NULL, report_time INTEGER DEFAULT 0 NOT NULL,
report_text BLOB SUB_TYPE TEXT CHARACTER SET UTF8 DEFAULT '' NOT NULL report_text BLOB SUB_TYPE TEXT CHARACTER SET UTF8 DEFAULT '' NOT NULL,
reported_post_text BLOB SUB_TYPE TEXT CHARACTER SET UTF8 DEFAULT '' NOT NULL
);; );;
ALTER TABLE phpbb_reports ADD PRIMARY KEY (report_id);; ALTER TABLE phpbb_reports ADD PRIMARY KEY (report_id);;

View file

@ -1108,7 +1108,8 @@ CREATE TABLE [phpbb_reports] (
[user_notify] [int] DEFAULT (0) NOT NULL , [user_notify] [int] DEFAULT (0) NOT NULL ,
[report_closed] [int] DEFAULT (0) NOT NULL , [report_closed] [int] DEFAULT (0) NOT NULL ,
[report_time] [int] DEFAULT (0) NOT NULL , [report_time] [int] DEFAULT (0) NOT NULL ,
[report_text] [text] DEFAULT ('') NOT NULL [report_text] [text] DEFAULT ('') NOT NULL ,
[reported_post_text] [text] DEFAULT ('') NOT NULL
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY] ) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
GO GO

View file

@ -647,6 +647,7 @@ CREATE TABLE phpbb_reports (
report_closed tinyint(1) UNSIGNED DEFAULT '0' NOT NULL, report_closed tinyint(1) UNSIGNED DEFAULT '0' NOT NULL,
report_time int(11) UNSIGNED DEFAULT '0' NOT NULL, report_time int(11) UNSIGNED DEFAULT '0' NOT NULL,
report_text mediumblob NOT NULL, report_text mediumblob NOT NULL,
reported_post_text mediumblob NOT NULL,
PRIMARY KEY (report_id), PRIMARY KEY (report_id),
KEY post_id (post_id), KEY post_id (post_id),
KEY pm_id (pm_id) KEY pm_id (pm_id)

View file

@ -647,6 +647,7 @@ CREATE TABLE phpbb_reports (
report_closed tinyint(1) UNSIGNED DEFAULT '0' NOT NULL, report_closed tinyint(1) UNSIGNED DEFAULT '0' NOT NULL,
report_time int(11) UNSIGNED DEFAULT '0' NOT NULL, report_time int(11) UNSIGNED DEFAULT '0' NOT NULL,
report_text mediumtext NOT NULL, report_text mediumtext NOT NULL,
reported_post_text mediumtext NOT NULL,
PRIMARY KEY (report_id), PRIMARY KEY (report_id),
KEY post_id (post_id), KEY post_id (post_id),
KEY pm_id (pm_id) KEY pm_id (pm_id)

View file

@ -1214,6 +1214,7 @@ CREATE TABLE phpbb_reports (
report_closed number(1) DEFAULT '0' NOT NULL, report_closed number(1) DEFAULT '0' NOT NULL,
report_time number(11) DEFAULT '0' NOT NULL, report_time number(11) DEFAULT '0' NOT NULL,
report_text clob DEFAULT '' , report_text clob DEFAULT '' ,
reported_post_text clob DEFAULT '' ,
CONSTRAINT pk_phpbb_reports PRIMARY KEY (report_id) CONSTRAINT pk_phpbb_reports PRIMARY KEY (report_id)
) )
/ /

View file

@ -853,6 +853,7 @@ CREATE TABLE phpbb_reports (
report_closed INT2 DEFAULT '0' NOT NULL CHECK (report_closed >= 0), report_closed INT2 DEFAULT '0' NOT NULL CHECK (report_closed >= 0),
report_time INT4 DEFAULT '0' NOT NULL CHECK (report_time >= 0), report_time INT4 DEFAULT '0' NOT NULL CHECK (report_time >= 0),
report_text TEXT DEFAULT '' NOT NULL, report_text TEXT DEFAULT '' NOT NULL,
reported_post_text TEXT DEFAULT '' NOT NULL,
PRIMARY KEY (report_id) PRIMARY KEY (report_id)
); );

View file

@ -627,7 +627,8 @@ CREATE TABLE phpbb_reports (
user_notify INTEGER UNSIGNED NOT NULL DEFAULT '0', user_notify INTEGER UNSIGNED NOT NULL DEFAULT '0',
report_closed INTEGER UNSIGNED NOT NULL DEFAULT '0', report_closed INTEGER UNSIGNED NOT NULL DEFAULT '0',
report_time INTEGER UNSIGNED NOT NULL DEFAULT '0', report_time INTEGER UNSIGNED NOT NULL DEFAULT '0',
report_text mediumtext(16777215) NOT NULL DEFAULT '' report_text mediumtext(16777215) NOT NULL DEFAULT '',
reported_post_text mediumtext(16777215) NOT NULL DEFAULT ''
); );
CREATE INDEX phpbb_reports_post_id ON phpbb_reports (post_id); CREATE INDEX phpbb_reports_post_id ON phpbb_reports (post_id);

View file

@ -185,7 +185,11 @@ $lang = array_merge($lang, array(
'ERR_WRONG_PATH_TO_PHPBB' => 'The phpBB path specified appears to be invalid.', 'ERR_WRONG_PATH_TO_PHPBB' => 'The phpBB path specified appears to be invalid.',
'EXPAND_VIEW' => 'Expand view', 'EXPAND_VIEW' => 'Expand view',
'EXTENSION' => 'Extension', 'EXTENSION' => 'Extension',
'EXTENSION_CONTROLLER_MISSING' => 'The extension <strong>%s</strong> is missing a controller class and cannot be accessed through the front-end.',
'EXTENSION_CLASS_WRONG_TYPE' => 'The extension controller class <strong>%s</strong> is not an instance of the phpbb_extension_controller_interface.',
'EXTENSION_DISABLED' => 'The extension <strong>%s</strong> is not enabled.',
'EXTENSION_DISABLED_AFTER_POSTING' => 'The extension <strong>%s</strong> has been deactivated and can no longer be displayed.', 'EXTENSION_DISABLED_AFTER_POSTING' => 'The extension <strong>%s</strong> has been deactivated and can no longer be displayed.',
'EXTENSION_DOES_NOT_EXIST' => 'The extension <strong>%s</strong> does not exist.',
'FAQ' => 'FAQ', 'FAQ' => 'FAQ',
'FAQ_EXPLAIN' => 'Frequently Asked Questions', 'FAQ_EXPLAIN' => 'Frequently Asked Questions',

View file

@ -300,10 +300,10 @@ $lang = array_merge($lang, array(
'PHP_REGISTER_GLOBALS_EXPLAIN' => 'phpBB will still run if this setting is enabled, but if possible, it is recommended that register_globals is disabled on your PHP install for security reasons.', 'PHP_REGISTER_GLOBALS_EXPLAIN' => 'phpBB will still run if this setting is enabled, but if possible, it is recommended that register_globals is disabled on your PHP install for security reasons.',
'PHP_SAFE_MODE' => 'Safe mode', 'PHP_SAFE_MODE' => 'Safe mode',
'PHP_SETTINGS' => 'PHP version and settings', 'PHP_SETTINGS' => 'PHP version and settings',
'PHP_SETTINGS_EXPLAIN' => '<strong>Required</strong> - You must be running at least version 5.2.0 of PHP in order to install phpBB. If <var>safe mode</var> is displayed below your PHP installation is running in that mode. This will impose limitations on remote administration and similar features.', 'PHP_SETTINGS_EXPLAIN' => '<strong>Required</strong> - You must be running at least version 5.3.2 of PHP in order to install phpBB. If <var>safe mode</var> is displayed below your PHP installation is running in that mode. This will impose limitations on remote administration and similar features.',
'PHP_URL_FOPEN_SUPPORT' => 'PHP setting <var>allow_url_fopen</var> is enabled', 'PHP_URL_FOPEN_SUPPORT' => 'PHP setting <var>allow_url_fopen</var> is enabled',
'PHP_URL_FOPEN_SUPPORT_EXPLAIN' => '<strong>Optional</strong> - This setting is optional, however certain phpBB functions like off-site avatars will not work properly without it.', 'PHP_URL_FOPEN_SUPPORT_EXPLAIN' => '<strong>Optional</strong> - This setting is optional, however certain phpBB functions like off-site avatars will not work properly without it.',
'PHP_VERSION_REQD' => 'PHP version >= 5.2.0', 'PHP_VERSION_REQD' => 'PHP version >= 5.3.2',
'POST_ID' => 'Post ID', 'POST_ID' => 'Post ID',
'PREFIX_FOUND' => 'A scan of your tables has shown a valid installation using <strong>%s</strong> as table prefix.', 'PREFIX_FOUND' => 'A scan of your tables has shown a valid installation using <strong>%s</strong> as table prefix.',
'PREPROCESS_STEP' => 'Executing pre-processing functions/queries', 'PREPROCESS_STEP' => 'Executing pre-processing functions/queries',

View file

@ -238,6 +238,7 @@ $lang = array_merge($lang, array(
'NO_POST' => 'You have to select a post in order to warn the user for a post.', 'NO_POST' => 'You have to select a post in order to warn the user for a post.',
'NO_POST_REPORT' => 'This post was not reported.', 'NO_POST_REPORT' => 'This post was not reported.',
'NO_POST_SELECTED' => 'You must select at least one post to perform this action.', 'NO_POST_SELECTED' => 'You must select at least one post to perform this action.',
'NO_POSTS_QUEUE' => 'There are no posts waiting for approval.',
'NO_REASON_DISAPPROVAL' => 'Please give an appropriate reason for disapproval.', 'NO_REASON_DISAPPROVAL' => 'Please give an appropriate reason for disapproval.',
'NO_REPORT' => 'No report found', 'NO_REPORT' => 'No report found',
'NO_REPORTS' => 'No reports found', 'NO_REPORTS' => 'No reports found',

View file

@ -1347,6 +1347,7 @@ switch ($mode)
if ($mode) if ($mode)
{ {
$params[] = "mode=$mode"; $params[] = "mode=$mode";
$u_first_char_params[] = "mode=$mode";
} }
$sort_params[] = "mode=$mode"; $sort_params[] = "mode=$mode";

View file

@ -71,8 +71,9 @@ if ($post_id)
trigger_error('POST_NOT_EXIST'); trigger_error('POST_NOT_EXIST');
} }
$forum_id = (int) $report_data['forum_id']; $forum_id = (int) $report_data['forum_id'];
$topic_id = (int) $report_data['topic_id']; $topic_id = (int) $report_data['topic_id'];
$reported_post_text = $report_data['post_text'];
$sql = 'SELECT * $sql = 'SELECT *
FROM ' . FORUMS_TABLE . ' FROM ' . FORUMS_TABLE . '
@ -130,6 +131,8 @@ else
$message .= '<br /><br />' . sprintf($user->lang['RETURN_PM'], '<a href="' . $redirect_url . '">', '</a>'); $message .= '<br /><br />' . sprintf($user->lang['RETURN_PM'], '<a href="' . $redirect_url . '">', '</a>');
trigger_error($message); trigger_error($message);
} }
$reported_post_text = $report_data['message_text'];
} }
// Submit report? // Submit report?
@ -155,7 +158,8 @@ if ($submit && $reason_id)
'user_notify' => (int) $user_notify, 'user_notify' => (int) $user_notify,
'report_closed' => 0, 'report_closed' => 0,
'report_time' => (int) time(), 'report_time' => (int) time(),
'report_text' => (string) $report_text 'report_text' => (string) $report_text,
'reported_post_text' => $reported_post_text,
); );
$sql = 'INSERT INTO ' . REPORTS_TABLE . ' ' . $db->sql_build_array('INSERT', $sql_ary); $sql = 'INSERT INTO ' . REPORTS_TABLE . ' ' . $db->sql_build_array('INSERT', $sql_ary);

View file

@ -78,7 +78,7 @@
</li> </li>
</ul> </ul>
<!-- ELSE --> <!-- ELSE -->
<p class="notopics"><strong><!-- IF S_TOPICS -->{L_NO_TOPICS_QUEUE}<!-- ELSE -->{L_UNAPPROVED_POSTS_ZERO_TOTAL}<!-- ENDIF --></strong></p> <p class="notopics"><strong><!-- IF S_TOPICS -->{L_NO_TOPICS_QUEUE}<!-- ELSE -->{L_NO_POSTS_QUEUE}<!-- ENDIF --></strong></p>
<!-- ENDIF --> <!-- ENDIF -->
<span class="corners-bottom"><span></span></span></div> <span class="corners-bottom"><span></span></span></div>

View file

@ -106,7 +106,7 @@ onload_functions.push('subPanels()');
<div class="inner"><span class="corners-top"><span></span></span> <div class="inner"><span class="corners-top"><span></span></span>
<div class="postbody" id="pr{postrow.POST_ID}"> <div class="postbody" id="pr{postrow.POST_ID}">
<ul class="profile-icons"><li class="info-icon"><a href="{postrow.U_POST_DETAILS}" title="{L_POST_DETAILS}"><span>{L_POST_DETAILS}</span></a></li><li>{L_SELECT}: <input type="checkbox" name="post_id_list[]" value="{postrow.POST_ID}"<!-- IF postrow.S_CHECKED --> checked="checked"<!-- ENDIF --> /></li></ul> <ul class="profile-icons"><li class="info-icon"><a href="{postrow.U_POST_DETAILS}" title="{L_POST_DETAILS}"><span>{L_POST_DETAILS}</span></a></li><li><label for="post_id_list_select_{postrow.POST_ID}">{L_SELECT}: <input type="checkbox" id="post_id_list_select_{postrow.POST_ID}" name="post_id_list[]" value="{postrow.POST_ID}"<!-- IF postrow.S_CHECKED --> checked="checked"<!-- ENDIF --> /></label></li></ul>
<h3><a href="{postrow.U_POST_DETAILS}">{postrow.POST_SUBJECT}</a></h3> <h3><a href="{postrow.U_POST_DETAILS}">{postrow.POST_SUBJECT}</a></h3>
<p class="author"><a href="#pr{postrow.POST_ID}">{postrow.MINI_POST_IMG}</a> {L_POSTED} {postrow.POST_DATE} {L_POST_BY_AUTHOR} <strong>{postrow.POST_AUTHOR_FULL}</strong><!-- IF postrow.U_MCP_DETAILS --> [ <a href="{postrow.U_MCP_DETAILS}">{L_POST_DETAILS}</a> ]<!-- ENDIF --></p> <p class="author"><a href="#pr{postrow.POST_ID}">{postrow.MINI_POST_IMG}</a> {L_POSTED} {postrow.POST_DATE} {L_POST_BY_AUTHOR} <strong>{postrow.POST_AUTHOR_FULL}</strong><!-- IF postrow.U_MCP_DETAILS --> [ <a href="{postrow.U_MCP_DETAILS}">{L_POST_DETAILS}</a> ]<!-- ENDIF --></p>
@ -158,6 +158,7 @@ onload_functions.push('subPanels()');
<!-- IF S_CAN_DELETE --><option value="delete_post">{L_DELETE_POSTS}</option><!-- ENDIF --> <!-- IF S_CAN_DELETE --><option value="delete_post">{L_DELETE_POSTS}</option><!-- ENDIF -->
<!-- IF S_CAN_MERGE --><option value="merge_posts"<!-- IF S_MERGE_VIEW --> selected="selected"<!-- ENDIF -->>{L_MERGE_POSTS}</option><!-- ENDIF --> <!-- IF S_CAN_MERGE --><option value="merge_posts"<!-- IF S_MERGE_VIEW --> selected="selected"<!-- ENDIF -->>{L_MERGE_POSTS}</option><!-- ENDIF -->
<!-- IF S_CAN_SPLIT --><option value="split_all"<!-- IF S_SPLIT_VIEW --> selected="selected"<!-- ENDIF -->>{L_SPLIT_POSTS}</option><option value="split_beyond">{L_SPLIT_AFTER}</option><!-- ENDIF --> <!-- IF S_CAN_SPLIT --><option value="split_all"<!-- IF S_SPLIT_VIEW --> selected="selected"<!-- ENDIF -->>{L_SPLIT_POSTS}</option><option value="split_beyond">{L_SPLIT_AFTER}</option><!-- ENDIF -->
<!-- IF S_CAN_SYNC --><option value="resync">{L_RESYNC}</option><!-- ENDIF -->
</select>&nbsp; </select>&nbsp;
<input class="button1" type="submit" name="mcp_topic_submit" value="{L_SUBMIT}" /> <input class="button1" type="submit" name="mcp_topic_submit" value="{L_SUBMIT}" />
<div><a href="#" onclick="marklist('mcp', 'post', true); return false;">{L_MARK_ALL}</a> :: <a href="#" onclick="marklist('mcp', 'post', false); return false;">{L_UNMARK_ALL}</a></div> <div><a href="#" onclick="marklist('mcp', 'post', true); return false;">{L_MARK_ALL}</a> :: <a href="#" onclick="marklist('mcp', 'post', false); return false;">{L_UNMARK_ALL}</a></div>

View file

@ -69,7 +69,7 @@
<!-- IF U_JABBER and S_JABBER_ENABLED --><dt>{L_JABBER}:</dt> <dd><a href="{U_JABBER}" onclick="popup(this.href, 550, 320); return false;">{L_SEND_JABBER_MESSAGE}</a></dd><!-- ELSEIF USER_JABBER --><dt>{L_JABBER}:</dt> <dd>{USER_JABBER}</dd><!-- ENDIF --> <!-- IF U_JABBER and S_JABBER_ENABLED --><dt>{L_JABBER}:</dt> <dd><a href="{U_JABBER}" onclick="popup(this.href, 550, 320); return false;">{L_SEND_JABBER_MESSAGE}</a></dd><!-- ELSEIF USER_JABBER --><dt>{L_JABBER}:</dt> <dd>{USER_JABBER}</dd><!-- ENDIF -->
<!-- IF S_PROFILE_FIELD1 --> <!-- IF S_PROFILE_FIELD1 -->
<!-- NOTE: Use a construct like this to include admin defined profile fields. Replace FIELD1 with the name of your field. --> <!-- NOTE: Use a construct like this to include admin defined profile fields. Replace FIELD1 with the name of your field. -->
<dt>{postrow.PROFILE_FIELD1_NAME}:</dt> <dd>{postrow.PROFILE_FIELD1_VALUE}</dd> <dt>{PROFILE_FIELD1_NAME}:</dt> <dd>{PROFILE_FIELD1_VALUE}</dd>
<!-- ENDIF --> <!-- ENDIF -->
</dl> </dl>
</div> </div>

View file

@ -17,7 +17,7 @@
<div class="inner"><span class="corners-top"><span></span></span> <div class="inner"><span class="corners-top"><span></span></span>
{topic_review_row.L_IGNORE_POST} {topic_review_row.L_IGNORE_POST}
<!-- ELSE --> <!-- ELSE -->
<div class="post <!-- IF topic_review_row.S_ROW_COUNT is odd -->bg1<!-- ELSE -->bg2<!-- ENDIF -->"> <div class="post <!-- IF topic_review_row.S_ROW_COUNT is odd -->bg1<!-- ELSE -->bg2<!-- ENDIF --><!-- IF topic_review_row.POST_ID == REPORTED_POST_ID --> reported<!-- ENDIF -->">
<div class="inner"><span class="corners-top"><span></span></span> <div class="inner"><span class="corners-top"><span></span></span>
<!-- ENDIF --> <!-- ENDIF -->

View file

@ -1,12 +1,51 @@
/* General Markup Styles /* CSS Reset http://meyerweb.com/eric/tools/css/reset/ v2.0 | 20110126
---------------------------------------- */ ---------------------------------------- */
html, body, div, span, applet, object, iframe,
* { h1, h2, h3, h4, h5, h6, p, blockquote, pre,
/* Reset browsers default margin, padding and font sizes */ a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed,
figure, figcaption, footer, header, hgroup,
menu, nav, output, ruby, section, summary,
time, mark, audio, video {
margin: 0; margin: 0;
padding: 0; padding: 0;
border: 0;
font-size: 100%;
font: inherit;
vertical-align: baseline;
}
/* HTML5 display-role reset for older browsers */
article, aside, details, figcaption, figure,
footer, header, hgroup, menu, nav, section {
display: block;
}
body {
line-height: 1;
}
ol, ul {
list-style: none;
}
blockquote, q {
quotes: none;
}
blockquote:before, blockquote:after,
q:before, q:after {
content: '';
content: none;
}
table {
border-collapse: collapse;
border-spacing: 0;
} }
/* General Markup Styles
---------------------------------------- */
html { html {
font-size: 100%; font-size: 100%;
/* Always show a scrollbar for short pages - stops the jump when the scrollbar appears. non-IE browsers */ /* Always show a scrollbar for short pages - stops the jump when the scrollbar appears. non-IE browsers */
@ -20,6 +59,7 @@ body {
background-color: #FFFFFF; background-color: #FFFFFF;
/*font-size: 62.5%; This sets the default font size to be equivalent to 10px */ /*font-size: 62.5%; This sets the default font size to be equivalent to 10px */
font-size: 10px; font-size: 10px;
line-height: normal;
margin: 0; margin: 0;
padding: 12px 0; padding: 12px 0;
} }
@ -99,6 +139,39 @@ p.right {
text-align: right; text-align: right;
} }
b, strong {
font-weight: bold;
}
i, em {
font-style: italic;
}
u {
text-decoration: underline;
}
ul {
list-style-type: disc;
}
ol {
list-style-type: decimal;
}
li {
display: list-item;
}
ul ul, ol ul {
list-style-type: circle;
}
ol ol ul, ol ul ul, ul ol ul, ul ul ul {
list-style-type: square;
}
/* Main blocks /* Main blocks
---------------------------------------- */ ---------------------------------------- */
#wrap { #wrap {

View file

@ -27,7 +27,7 @@
</tr> </tr>
<!-- BEGINELSE --> <!-- BEGINELSE -->
<tr> <tr>
<td class="row1" colspan="4" height="30" align="center" valign="middle"><span class="gen"><!-- IF S_TOPICS -->{L_NO_TOPICS_QUEUE}<!-- ELSE -->{L_UNAPPROVED_POSTS_ZERO_TOTAL}<!-- ENDIF --></span></td> <td class="row1" colspan="4" height="30" align="center" valign="middle"><span class="gen"><!-- IF S_TOPICS -->{L_NO_TOPICS_QUEUE}<!-- ELSE -->{L_NO_POSTS_QUEUE}<!-- ENDIF --></span></td>
</tr> </tr>
<!-- END postrow --> <!-- END postrow -->
<tr> <tr>

View file

@ -135,6 +135,7 @@
<!-- IF S_CAN_DELETE --><option value="delete_post">{L_DELETE_POSTS}</option><!-- ENDIF --> <!-- IF S_CAN_DELETE --><option value="delete_post">{L_DELETE_POSTS}</option><!-- ENDIF -->
<!-- IF S_CAN_MERGE --><option value="merge_posts"<!-- IF ACTION eq 'merge' --> selected="selected"<!-- ENDIF -->>{L_MERGE_POSTS}</option><!-- ENDIF --> <!-- IF S_CAN_MERGE --><option value="merge_posts"<!-- IF ACTION eq 'merge' --> selected="selected"<!-- ENDIF -->>{L_MERGE_POSTS}</option><!-- ENDIF -->
<!-- IF S_CAN_SPLIT --><option value="split_all"<!-- IF ACTION eq 'split' --> selected="selected"<!-- ENDIF -->>{L_SPLIT_POSTS}</option><option value="split_beyond">{L_SPLIT_AFTER}</option><!-- ENDIF --> <!-- IF S_CAN_SPLIT --><option value="split_all"<!-- IF ACTION eq 'split' --> selected="selected"<!-- ENDIF -->>{L_SPLIT_POSTS}</option><option value="split_beyond">{L_SPLIT_AFTER}</option><!-- ENDIF -->
<!-- IF S_CAN_SYNC --><option value="resync">{L_RESYNC}</option><!-- ENDIF -->
</select>&nbsp;<input class="btnmain" type="submit" name="mcp_topic_submit" value="{L_SUBMIT}" /></td> </select>&nbsp;<input class="btnmain" type="submit" name="mcp_topic_submit" value="{L_SUBMIT}" /></td>
</tr> </tr>
</table> </table>

View file

@ -51,6 +51,13 @@
<table width="100%" cellspacing="0" cellpadding="2"> <table width="100%" cellspacing="0" cellpadding="2">
<tr> <tr>
<td> <td>
<!-- IF topic_review_row.POST_ID == REPORTED_POST_ID -->
<table width="100%" cellspacing="0">
<tr>
<span class="postreported">{REPORTED_IMG}</span>
</tr>
</table>
<!-- ENDIF -->
<div class="postbody">{topic_review_row.MESSAGE}</div> <div class="postbody">{topic_review_row.MESSAGE}</div>
<!-- IF topic_review_row.S_HAS_ATTACHMENTS --> <!-- IF topic_review_row.S_HAS_ATTACHMENTS -->

View file

@ -14,10 +14,6 @@
<testsuites> <testsuites>
<testsuite name="phpBB Test Suite"> <testsuite name="phpBB Test Suite">
<directory suffix="_test.php">./tests/</directory> <directory suffix="_test.php">./tests/</directory>
<exclude>./tests/functional</exclude>
</testsuite>
<testsuite name="phpBB Functional Tests">
<directory suffix="_test.php" phpVersion="5.3.0" phpVersionOperator=">=">./tests/functional</directory>
</testsuite> </testsuite>
</testsuites> </testsuites>

View file

@ -14,10 +14,6 @@
<testsuites> <testsuites>
<testsuite name="phpBB Test Suite"> <testsuite name="phpBB Test Suite">
<directory suffix="_test.php">./tests/</directory> <directory suffix="_test.php">./tests/</directory>
<exclude>./tests/functional</exclude>
</testsuite>
<testsuite name="phpBB Functional Tests">
<directory suffix="_test.php" phpVersion="5.3.0" phpVersionOperator=">=">./tests/functional</directory>
</testsuite> </testsuite>
</testsuites> </testsuites>

View file

@ -14,10 +14,6 @@
<testsuites> <testsuites>
<testsuite name="phpBB Test Suite"> <testsuite name="phpBB Test Suite">
<directory suffix="_test.php">./tests/</directory> <directory suffix="_test.php">./tests/</directory>
<exclude>./tests/functional</exclude>
</testsuite>
<testsuite name="phpBB Functional Tests">
<directory suffix="_test.php" phpVersion="5.3.0" phpVersionOperator=">=">./tests/functional</directory>
</testsuite> </testsuite>
</testsuites> </testsuites>

View file

@ -25,8 +25,4 @@ require_once 'test_framework/phpbb_test_case_helpers.php';
require_once 'test_framework/phpbb_test_case.php'; require_once 'test_framework/phpbb_test_case.php';
require_once 'test_framework/phpbb_database_test_case.php'; require_once 'test_framework/phpbb_database_test_case.php';
require_once 'test_framework/phpbb_database_test_connection_manager.php'; require_once 'test_framework/phpbb_database_test_connection_manager.php';
require_once 'test_framework/phpbb_functional_test_case.php';
if (version_compare(PHP_VERSION, '5.3.0-dev', '>='))
{
require_once 'test_framework/phpbb_functional_test_case.php';
}

View file

@ -0,0 +1,153 @@
<?php
/**
*
* @package testing
* @copyright (c) 2011 phpBB Group
* @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License v2
*
*/
/**
* @group functional
*/
class phpbb_functional_extension_controller_test extends phpbb_functional_test_case
{
protected $phpbb_extension_manager;
/**
* This should only be called once before the tests are run.
* This is used to copy the fixtures to the phpBB install
*/
static public function setUpBeforeClass()
{
global $phpbb_root_path;
parent::setUpBeforeClass();
// these directories need to be created before the files can be copied
$directories = array(
$phpbb_root_path . 'ext/error/class/',
$phpbb_root_path . 'ext/error/classtype/',
$phpbb_root_path . 'ext/error/disabled/',
$phpbb_root_path . 'ext/foo/bar/',
$phpbb_root_path . 'ext/foo/bar/styles/prosilver/template/',
$phpbb_root_path . 'ext/foobar/',
$phpbb_root_path . 'ext/foobar/styles/prosilver/template/',
);
foreach ($directories as $dir)
{
if (!is_dir($dir))
{
mkdir($dir, 0777, true);
}
}
$fixtures = array(
'error/class/controller.php',
'error/class/ext.php',
'error/classtype/controller.php',
'error/classtype/ext.php',
'error/disabled/controller.php',
'error/disabled/ext.php',
'foo/bar/controller.php',
'foo/bar/ext.php',
'foo/bar/styles/prosilver/template/foobar_body.html',
'foobar/controller.php',
'foobar/ext.php',
'foobar/styles/prosilver/template/foobar_body.html',
);
foreach ($fixtures as $fixture)
{
if (!copy("tests/functional/fixtures/ext/$fixture", "{$phpbb_root_path}ext/$fixture"))
{
echo 'Could not copy file ' . $fixture;
}
}
}
public static function tearDownAfterClass()
{
$phpbb_root_path = self::$config['phpbb_functional_path'];
// @todo delete the fixtures from the $phpbb_root_path board
// Note that it might be best to find a public domain function
// and port it into here instead of writing it from scratch
}
public function setUp()
{
parent::setUp();
$this->phpbb_extension_manager = $this->get_extension_manager();
$this->purge_cache();
}
/**
* Check an extension at ./ext/foobar/ which should have the class
* phpbb_ext_foobar_controller
*/
public function test_foobar()
{
$this->phpbb_extension_manager->enable('foobar');
$crawler = $this->request('GET', 'index.php?ext=foobar');
$this->assertContains("This is for testing purposes.", $crawler->filter('#page-body')->text());
$this->phpbb_extension_manager->purge('foobar');
}
/**
* Check an extension at ./ext/foo/bar/ which should have the class
* phpbb_ext_foo_bar_controller
*/
public function test_foo_bar()
{
$this->phpbb_extension_manager->enable('foo/bar');
$crawler = $this->request('GET', 'index.php?ext=foo/bar');
$this->assertContains("This is for testing purposes.", $crawler->filter('#page-body')->text());
$this->phpbb_extension_manager->purge('foo/bar');
}
/**
* Check the error produced by extension at ./ext/error/class which has class
* phpbb_ext_foobar_controller
*/
public function test_error_class_name()
{
$this->phpbb_extension_manager->enable('error/class');
$crawler = $this->request('GET', 'index.php?ext=error/class');
$this->assertContains("The extension error/class is missing a controller class and cannot be accessed through the front-end.", $crawler->filter('#message')->text());
$this->phpbb_extension_manager->purge('error/class');
}
/**
* Check the error produced by extension at ./ext/error/classtype which has class
* phpbb_ext_error_classtype_controller but does not implement phpbb_extension_controller_interface
*/
public function test_error_class_type()
{
$this->phpbb_extension_manager->enable('error/classtype');
$crawler = $this->request('GET', 'index.php?ext=error/classtype');
$this->assertContains("The extension controller class phpbb_ext_error_classtype_controller is not an instance of the phpbb_extension_controller_interface.", $crawler->filter('#message')->text());
$this->phpbb_extension_manager->purge('error/classtype');
}
/**
* Check the error produced by extension at ./ext/error/disabled that is (obviously)
* a disabled extension
*/
public function test_error_ext_disabled()
{
$crawler = $this->request('GET', 'index.php?ext=error/disabled');
$this->assertContains("The extension error/disabled is not enabled", $crawler->filter('#message')->text());
}
/**
* Check the error produced by extension at ./ext/error/404 that is (obviously)
* not existant
*/
public function test_error_ext_missing()
{
$crawler = $this->request('GET', 'index.php?ext=error/404');
$this->assertContains("The extension error/404 does not exist.", $crawler->filter('#message')->text());
}
}

View file

@ -0,0 +1,17 @@
<?php
class phpbb_ext_foobar_controller implements phpbb_extension_controller_interface
{
public function handle()
{
global $template;
$template->set_ext_dir_prefix($phpbb_root_path . 'ext/error/class/');
$template->set_filenames(array(
'body' => 'index_body.html'
));
page_header('Test extension');
page_footer();
}
}

View file

@ -0,0 +1,6 @@
<?php
class phpbb_ext_error_class_ext extends phpbb_extension_base
{
}

View file

@ -0,0 +1,17 @@
<?php
class phpbb_ext_error_classtype_controller
{
public function handle()
{
global $template;
$template->set_ext_dir_prefix($phpbb_root_path . 'ext/error/classtype/');
$template->set_filenames(array(
'body' => 'index_body.html'
));
page_header('Test extension');
page_footer();
}
}

View file

@ -0,0 +1,6 @@
<?php
class phpbb_ext_error_classtype_ext extends phpbb_extension_base
{
}

View file

@ -0,0 +1,17 @@
<?php
class phpbb_ext_error_disabled_controller implements phpbb_extension_controller_interface
{
public function handle()
{
global $template;
$template->set_ext_dir_prefix($phpbb_root_path . 'ext/error/disabled/');
$template->set_filenames(array(
'body' => 'index_body.html'
));
page_header('Test extension');
page_footer();
}
}

View file

@ -0,0 +1,6 @@
<?php
class phpbb_ext_error_disabled_ext extends phpbb_extension_base
{
}

View file

@ -0,0 +1,17 @@
<?php
class phpbb_ext_foo_bar_controller implements phpbb_extension_controller_interface
{
public function handle()
{
global $template;
$template->set_ext_dir_prefix($phpbb_root_path . 'ext/foo/bar/');
$template->set_filenames(array(
'body' => 'foobar_body.html'
));
page_header('Test extension');
page_footer();
}
}

View file

@ -0,0 +1,6 @@
<?php
class phpbb_ext_foo_bar_ext extends phpbb_extension_base
{
}

View file

@ -0,0 +1,5 @@
<!-- INCLUDE overall_header.html -->
<div id="welcome">This is for testing purposes.</div>
<!-- INCLUDE overall_footer.html -->

View file

@ -0,0 +1,17 @@
<?php
class phpbb_ext_foobar_controller implements phpbb_extension_controller_interface
{
public function handle()
{
global $template;
$template->set_ext_dir_prefix($phpbb_root_path . 'ext/foobar/');
$template->set_filenames(array(
'body' => 'foobar_body.html'
));
page_header('Test extension');
page_footer();
}
}

View file

@ -0,0 +1,6 @@
<?php
class phpbb_ext_foobar_ext extends phpbb_extension_base
{
}

View file

@ -0,0 +1,5 @@
<!-- INCLUDE overall_header.html -->
<div id="welcome">This is for testing purposes.</div>
<!-- INCLUDE overall_footer.html -->

View file

@ -14,6 +14,10 @@ class phpbb_functional_test_case extends phpbb_test_case
protected $client; protected $client;
protected $root_url; protected $root_url;
protected $cache = null;
protected $db = null;
protected $extension_manager = null;
static protected $config = array(); static protected $config = array();
static protected $already_installed = false; static protected $already_installed = false;
@ -66,6 +70,60 @@ class phpbb_functional_test_case extends phpbb_test_case
} }
} }
protected function get_db()
{
global $phpbb_root_path, $phpEx;
// so we don't reopen an open connection
if (!($this->db instanceof dbal))
{
if (!class_exists('dbal_' . self::$config['dbms']))
{
include($phpbb_root_path . 'includes/db/' . self::$config['dbms'] . ".$phpEx");
}
$sql_db = 'dbal_' . self::$config['dbms'];
$this->db = new $sql_db();
$this->db->sql_connect(self::$config['dbhost'], self::$config['dbuser'], self::$config['dbpasswd'], self::$config['dbname'], self::$config['dbport']);
}
return $this->db;
}
protected function get_cache_driver()
{
if (!$this->cache)
{
$this->cache = new phpbb_cache_driver_file;
}
return $this->cache;
}
protected function purge_cache()
{
$cache = $this->get_cache_driver();
$cache->purge();
$cache->unload();
$cache->load();
}
protected function get_extension_manager()
{
global $phpbb_root_path, $phpEx;
if (!$this->extension_manager)
{
$this->extension_manager = new phpbb_extension_manager(
$this->get_db(),
self::$config['table_prefix'] . 'ext',
$phpbb_root_path,
".$phpEx",
$this->get_cache_driver()
);
}
return $this->extension_manager;
}
protected function install_board() protected function install_board()
{ {
global $phpbb_root_path, $phpEx; global $phpbb_root_path, $phpEx;

View file

@ -0,0 +1,34 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit backupGlobals="true"
backupStaticAttributes="true"
colors="true"
convertErrorsToExceptions="true"
convertNoticesToExceptions="true"
convertWarningsToExceptions="true"
processIsolation="false"
stopOnFailure="false"
syntaxCheck="true"
strict="true"
bootstrap="../tests/bootstrap.php">
<testsuites>
<testsuite name="phpBB Test Suite">
<directory suffix="_test.php">../tests/</directory>
</testsuite>
</testsuites>
<groups>
<exclude>
<group>slow</group>
</exclude>
</groups>
<php>
<server name="PHPBB_TEST_DBMS" value="mysqli" />
<server name="PHPBB_TEST_DBHOST" value="0.0.0.0" />
<server name="PHPBB_TEST_DBPORT" value="3306" />
<server name="PHPBB_TEST_DBNAME" value="phpbb_tests" />
<server name="PHPBB_TEST_DBUSER" value="root" />
<server name="PHPBB_TEST_DBPASSWD" value="" />
<server name="PHPBB_TEST_TABLE_PREFIX" value="phpbb_"/>
</php>
</phpunit>

View file

@ -0,0 +1,36 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit backupGlobals="true"
backupStaticAttributes="true"
colors="true"
convertErrorsToExceptions="true"
convertNoticesToExceptions="true"
convertWarningsToExceptions="true"
processIsolation="false"
stopOnFailure="false"
syntaxCheck="true"
strict="true"
bootstrap="../tests/bootstrap.php">
<testsuites>
<testsuite name="phpBB Test Suite">
<directory suffix="_test.php">../tests/</directory>
</testsuite>
</testsuites>
<groups>
<exclude>
<group>slow</group>
</exclude>
</groups>
<php>
<!-- "Real" test database -->
<!-- uncomment, otherwise sqlite memory runs -->
<server name="PHPBB_TEST_DBMS" value="postgres"/>
<server name="PHPBB_TEST_DBHOST" value="localhost" />
<server name="PHPBB_TEST_DBPORT" value="5432" />
<server name="PHPBB_TEST_DBNAME" value="phpbb_tests" />
<server name="PHPBB_TEST_DBUSER" value="postgres" />
<server name="PHPBB_TEST_DBPASSWD" value="" />
<server name="PHPBB_TEST_TABLE_PREFIX" value="phpbb_"/>
</php>
</phpunit>