This is an automated email from the git hooks/post-receive script. s k u n n y k p u s h e d a c o m m i t t o b r a n c h o l d f o r u m in repository www/forum.xfce.org.
commit 1c9897a1fc53e08139dd3d6d91b5d8d8825b4b8b Author: Nick Schermer <n...@xfce.org> Date: Sun Feb 9 20:08:18 2014 +0100 Upgrade to fluxbb 1.5.6. --- admin_bans.php | 10 +++++----- admin_categories.php | 6 +++--- admin_censoring.php | 4 ++-- admin_forums.php | 8 ++++---- admin_groups.php | 8 ++++---- admin_maintenance.php | 4 ++-- admin_options.php | 22 +++++++++++----------- admin_permissions.php | 6 +++--- admin_reports.php | 4 ++-- admin_users.php | 14 +++++++------- db_update.php | 2 +- delete.php | 4 ++-- edit.php | 4 ++-- footer.php | 2 +- include/cache.php | 2 +- include/common.php | 2 +- include/functions.php | 29 +++++++++++++++++++++-------- index.php | 2 +- install.php | 2 +- lang/English/common.php | 1 + misc.php | 3 +++ moderate.php | 4 +++- post.php | 5 +++++ profile.php | 14 ++++++++++---- search.php | 2 +- style/Air.css | 4 ++++ style/Earth.css | 4 ++++ style/Fire.css | 4 ++++ userlist.php | 2 +- viewforum.php | 7 ++----- 30 files changed, 112 insertions(+), 73 deletions(-) diff --git a/admin_bans.php b/admin_bans.php index fa3c0ed..5d6d5b5 100644 --- a/admin_bans.php +++ b/admin_bans.php @@ -116,7 +116,7 @@ if (isset($_REQUEST['add_ban']) || isset($_GET['edit_ban'])) <?php endif; ?> <fieldset> <legend><?php echo $lang_admin_bans['Ban advanced subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_bans['Username label'] ?></th> <td> @@ -147,7 +147,7 @@ if (isset($_REQUEST['add_ban']) || isset($_GET['edit_ban'])) <fieldset> <legend><?php echo $lang_admin_bans['Message expiry subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_bans['Ban message label'] ?></th> <td> @@ -407,7 +407,7 @@ else if (isset($_GET['find_ban'])) <h2><span><?php echo $lang_admin_bans['Results head'] ?></span></h2> <div class="box"> <div class="inbox"> - <table cellspacing="0"> + <table> <thead> <tr> <th class="tcl" scope="col"><?php echo $lang_admin_bans['Results username head'] ?></th> @@ -489,7 +489,7 @@ generate_admin_menu('bans'); <fieldset> <legend><?php echo $lang_admin_bans['Add ban subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_bans['Username label'] ?><div><input type="submit" name="add_ban" value="<?php echo $lang_admin_common['Add'] ?>" tabindex="2" /></div></th> <td> @@ -513,7 +513,7 @@ generate_admin_menu('bans'); <legend><?php echo $lang_admin_bans['Ban search subhead'] ?></legend> <div class="infldset"> <p><?php echo $lang_admin_bans['Ban search info'] ?></p> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_bans['Username label'] ?></th> <td><input type="text" name="form[username]" size="25" maxlength="25" tabindex="4" /></td> diff --git a/admin_categories.php b/admin_categories.php index dee5bd7..756540a 100644 --- a/admin_categories.php +++ b/admin_categories.php @@ -175,7 +175,7 @@ generate_admin_menu('categories'); <fieldset> <legend><?php echo $lang_admin_categories['Add categories subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_categories['Add category label'] ?><div><input type="submit" name="add_cat" value="<?php echo $lang_admin_categories['Add new submit'] ?>" tabindex="2" /></div></th> <td> @@ -197,7 +197,7 @@ generate_admin_menu('categories'); <fieldset> <legend><?php echo $lang_admin_categories['Delete categories subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_categories['Delete category label'] ?><div><input type="submit" name="del_cat" value="<?php echo $lang_admin_common['Delete'] ?>" tabindex="4" /></div></th> <td> @@ -227,7 +227,7 @@ generate_admin_menu('categories'); <fieldset> <legend><?php echo $lang_admin_categories['Edit categories subhead'] ?></legend> <div class="infldset"> - <table id="categoryedit" cellspacing="0" > + <table id="categoryedit"> <thead> <tr> <th class="tcl" scope="col"><?php echo $lang_admin_categories['Category name label'] ?></th> diff --git a/admin_censoring.php b/admin_censoring.php index 420ca62..94a4f0a 100644 --- a/admin_censoring.php +++ b/admin_censoring.php @@ -101,7 +101,7 @@ generate_admin_menu('censoring'); <legend><?php echo $lang_admin_censoring['Add word subhead'] ?></legend> <div class="infldset"> <p><?php echo $lang_admin_censoring['Add word info'].' '.($pun_config['o_censoring'] == '1' ? sprintf($lang_admin_censoring['Censoring enabled'], '<a href="admin_options.php#censoring">'.$lang_admin_common['Options'].'</a>') : sprintf($lang_admin_censoring['Censoring disabled'], '<a href="admin_options.php#censoring">'.$lang_admin_common['Options'].'</a>')) ?></p> - <table cellspacing="0"> + <table> <thead> <tr> <th class="tcl" scope="col"><?php echo $lang_admin_censoring['Censored word label'] ?></th> @@ -131,7 +131,7 @@ if ($db->num_rows($result)) { ?> - <table cellspacing="0" > + <table> <thead> <tr> <th class="tcl" scope="col"><?php echo $lang_admin_censoring['Censored word label'] ?></th> diff --git a/admin_forums.php b/admin_forums.php index 60924e6..2c22411 100644 --- a/admin_forums.php +++ b/admin_forums.php @@ -245,7 +245,7 @@ else if (isset($_GET['edit_forum'])) <fieldset> <legend><?php echo $lang_admin_forums['Edit details subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_forums['Forum name label'] ?></th> <td><input type="text" name="forum_name" size="35" maxlength="80" value="<?php echo pun_htmlspecialchars($cur_forum['forum_name']) ?>" tabindex="1" /></td> @@ -294,7 +294,7 @@ else if (isset($_GET['edit_forum'])) <legend><?php echo $lang_admin_forums['Group permissions subhead'] ?></legend> <div class="infldset"> <p><?php printf($lang_admin_forums['Group permissions info'], '<a href="admin_groups.php">'.$lang_admin_common['User groups'].'</a>') ?></p> - <table id="forumperms" cellspacing="0"> + <table id="forumperms"> <thead> <tr> <th class="atcl"> </th> @@ -383,7 +383,7 @@ if ($db->num_rows($result) > 0) <fieldset> <legend><?php echo $lang_admin_forums['Create new subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_forums['Add forum label'] ?><div><input type="submit" name="add_forum" value="<?php echo $lang_admin_forums['Add forum'] ?>" tabindex="2" /></div></th> <td> @@ -454,7 +454,7 @@ while ($cur_forum = $db->fetch_assoc($result)) <fieldset> <legend><?php echo $lang_admin_forums['Category subhead'] ?> <?php echo pun_htmlspecialchars($cur_forum['cat_name']) ?></legend> <div class="infldset"> - <table cellspacing="0"> + <table> <thead> <tr> <th class="tcl"><?php echo $lang_admin_common['Action'] ?></th> diff --git a/admin_groups.php b/admin_groups.php index e2c4584..1e3f8cf 100644 --- a/admin_groups.php +++ b/admin_groups.php @@ -71,7 +71,7 @@ if (isset($_POST['add_group']) || isset($_GET['edit_group'])) <legend><?php echo $lang_admin_groups['Group settings subhead'] ?></legend> <div class="infldset"> <p><?php echo $lang_admin_groups['Group settings info'] ?></p> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_groups['Group title label'] ?></th> <td> @@ -540,7 +540,7 @@ generate_admin_menu('groups'); <fieldset> <legend><?php echo $lang_admin_groups['Add group subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_groups['New group label'] ?><div><input type="submit" name="add_group" value="<?php echo $lang_admin_common['Add'] ?>" tabindex="2" /></div></th> <td> @@ -571,7 +571,7 @@ foreach ($groups as $cur_group) <fieldset> <legend><?php echo $lang_admin_groups['Default group subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_groups['Default group label'] ?><div><input type="submit" name="set_default_group" value="<?php echo $lang_admin_common['Save'] ?>" tabindex="4" /></div></th> <td> @@ -609,7 +609,7 @@ foreach ($groups as $cur_group) <legend><?php echo $lang_admin_groups['Edit groups subhead'] ?></legend> <div class="infldset"> <p><?php echo $lang_admin_groups['Edit groups info'] ?></p> - <table cellspacing="0"> + <table> <?php $cur_index = 5; diff --git a/admin_maintenance.php b/admin_maintenance.php index df97a60..91563c9 100644 --- a/admin_maintenance.php +++ b/admin_maintenance.php @@ -262,7 +262,7 @@ generate_admin_menu('maintenance'); <legend><?php echo $lang_admin_maintenance['Rebuild index subhead'] ?></legend> <div class="infldset"> <p><?php printf($lang_admin_maintenance['Rebuild index info'], '<a href="admin_options.php#maintenance">'.$lang_admin_common['Maintenance mode'].'</a>') ?></p> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_maintenance['Posts per cycle label'] ?></th> <td> @@ -297,7 +297,7 @@ generate_admin_menu('maintenance'); <fieldset> <legend><?php echo $lang_admin_maintenance['Prune subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_maintenance['Days old label'] ?></th> <td> diff --git a/admin_options.php b/admin_options.php index 217389d..d0988be 100644 --- a/admin_options.php +++ b/admin_options.php @@ -238,7 +238,7 @@ generate_admin_menu('options'); <fieldset> <legend><?php echo $lang_admin_options['Essentials subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_options['Board title label'] ?></th> <td> @@ -372,7 +372,7 @@ generate_admin_menu('options'); <fieldset> <legend><?php echo $lang_admin_options['Timeouts subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_options['Time format label'] ?></th> <td> @@ -416,7 +416,7 @@ generate_admin_menu('options'); <fieldset> <legend><?php echo $lang_admin_options['Display subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_options['Version number label'] ?></th> <td> @@ -508,7 +508,7 @@ generate_admin_menu('options'); <fieldset> <legend><?php echo $lang_admin_options['Features subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_options['Quick post label'] ?></th> <td> @@ -596,7 +596,7 @@ generate_admin_menu('options'); <fieldset> <legend><?php echo $lang_admin_options['Feed subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_options['Default feed label'] ?></th> <td> @@ -631,7 +631,7 @@ generate_admin_menu('options'); <fieldset> <legend><?php echo $lang_admin_options['Reports subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_options['Reporting method label'] ?></th> <td> @@ -656,7 +656,7 @@ generate_admin_menu('options'); <fieldset> <legend><?php echo $lang_admin_options['Avatars subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_options['Use avatars label'] ?></th> <td> @@ -701,7 +701,7 @@ generate_admin_menu('options'); <fieldset> <legend><?php echo $lang_admin_options['E-mail subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_options['Admin e-mail label'] ?></th> <td> @@ -772,7 +772,7 @@ generate_admin_menu('options'); <fieldset> <legend><?php echo $lang_admin_options['Registration subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_options['Allow new label'] ?></th> <td> @@ -829,7 +829,7 @@ generate_admin_menu('options'); <fieldset> <legend><?php echo $lang_admin_options['Announcement subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_options['Display announcement label'] ?></th> <td> @@ -853,7 +853,7 @@ generate_admin_menu('options'); <fieldset> <legend><?php echo $lang_admin_options['Maintenance subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><a name="maintenance"></a><?php echo $lang_admin_options['Maintenance mode label'] ?></th> <td> diff --git a/admin_permissions.php b/admin_permissions.php index 23b236d..806b651 100644 --- a/admin_permissions.php +++ b/admin_permissions.php @@ -63,7 +63,7 @@ generate_admin_menu('permissions'); <fieldset> <legend><?php echo $lang_admin_permissions['Posting subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_permissions['BBCode label'] ?></th> <td> @@ -112,7 +112,7 @@ generate_admin_menu('permissions'); <fieldset> <legend><?php echo $lang_admin_permissions['Signatures subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_permissions['BBCode sigs label'] ?></th> <td> @@ -159,7 +159,7 @@ generate_admin_menu('permissions'); <fieldset> <legend><?php echo $lang_admin_permissions['Registration subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_permissions['Banned e-mail label'] ?></th> <td> diff --git a/admin_reports.php b/admin_reports.php index f2ce80d..07351e6 100644 --- a/admin_reports.php +++ b/admin_reports.php @@ -76,7 +76,7 @@ if ($db->num_rows($result)) <fieldset> <legend><?php printf($lang_admin_reports['Report subhead'], format_time($cur_report['created'])) ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php printf($lang_admin_reports['Reported by'], $reporter) ?></th> <td class="location"><?php echo implode(' ', $report_location) ?></td> @@ -140,7 +140,7 @@ if ($db->num_rows($result)) <fieldset> <legend><?php printf($lang_admin_reports['Zapped subhead'], format_time($cur_report['zapped']), $zapped_by) ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php printf($lang_admin_reports['Reported by'], $reporter) ?></th> <td class="location"><?php echo implode(' ', $report_location) ?></td> diff --git a/admin_users.php b/admin_users.php index 06d338e..fd57d86 100644 --- a/admin_users.php +++ b/admin_users.php @@ -63,7 +63,7 @@ if (isset($_GET['ip_stats'])) <h2><span><?php echo $lang_admin_users['Results head'] ?></span></h2> <div class="box"> <div class="inbox"> - <table cellspacing="0"> + <table> <thead> <tr> <th class="tcl" scope="col"><?php echo $lang_admin_users['Results IP address head'] ?></th> @@ -164,7 +164,7 @@ if (isset($_GET['show_users'])) <h2><span><?php echo $lang_admin_users['Results head'] ?></span></h2> <div class="box"> <div class="inbox"> - <table cellspacing="0"> + <table> <thead> <tr> <th class="tcl" scope="col"><?php echo $lang_admin_users['Results username head'] ?></th> @@ -361,7 +361,7 @@ else if (isset($_POST['move_users']) || isset($_POST['move_users_comply'])) <fieldset> <legend><?php echo $lang_admin_users['Move users subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_users['New group label'] ?></th> <td> @@ -643,7 +643,7 @@ else if (isset($_POST['ban_users']) || isset($_POST['ban_users_comply'])) <fieldset> <legend><?php echo $lang_admin_users['Message expiry subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_users['Ban message label'] ?></th> <td> @@ -839,7 +839,7 @@ else if (isset($_GET['find_user'])) <h2><span><?php echo $lang_admin_users['Results head'] ?></span></h2> <div class="box"> <div class="inbox"> - <table cellspacing="0"> + <table> <thead> <tr> <th class="tcl" scope="col"><?php echo $lang_admin_users['Results username head'] ?></th> @@ -935,7 +935,7 @@ else <legend><?php echo $lang_admin_users['User search subhead'] ?></legend> <div class="infldset"> <p><?php echo $lang_admin_users['User search info'] ?></p> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_users['Username label'] ?></th> <td><input type="text" name="form[username]" size="25" maxlength="25" tabindex="2" /></td> @@ -1074,7 +1074,7 @@ else <fieldset> <legend><?php echo $lang_admin_users['IP search subhead'] ?></legend> <div class="infldset"> - <table class="aligntop" cellspacing="0"> + <table class="aligntop"> <tr> <th scope="row"><?php echo $lang_admin_users['IP address label'] ?><div><input type="submit" value="<?php echo $lang_admin_users['Find IP address'] ?>" tabindex="26" /></div></th> <td><input type="text" name="show_users" size="18" maxlength="15" tabindex="24" /> diff --git a/db_update.php b/db_update.php index 9d03a84..d8307a1 100644 --- a/db_update.php +++ b/db_update.php @@ -7,7 +7,7 @@ */ // The FluxBB version this script updates to -define('UPDATE_TO', '1.5.5'); +define('UPDATE_TO', '1.5.6'); define('UPDATE_TO_DB_REVISION', 20); define('UPDATE_TO_SI_REVISION', 2); diff --git a/delete.php b/delete.php index 46e2d9b..e253bb4 100644 --- a/delete.php +++ b/delete.php @@ -51,8 +51,8 @@ require PUN_ROOT.'lang/'.$pun_user['language'].'/delete.php'; if (isset($_POST['delete'])) { - if ($is_admmod) - confirm_referrer('delete.php'); + // Make sure they got here from the site + confirm_referrer('delete.php'); require PUN_ROOT.'include/search_idx.php'; diff --git a/edit.php b/edit.php index 0d9d331..d47ed5c 100644 --- a/edit.php +++ b/edit.php @@ -56,8 +56,8 @@ $errors = array(); if (isset($_POST['form_sent'])) { - if ($is_admmod) - confirm_referrer('edit.php'); + // Make sure they got here from the site + confirm_referrer('edit.php'); // If it's a topic it must contain a subject if ($can_edit_subject) diff --git a/footer.php b/footer.php index b6b8a7a..2e3487c 100644 --- a/footer.php +++ b/footer.php @@ -40,7 +40,7 @@ if (isset($footer_style) && ($footer_style == 'viewforum' || $footer_style == 'v { echo "\t\t\t".'<dl>'."\n"; echo "\t\t\t\t".'<dt><strong>'.$lang_topic['Mod controls'].'</strong></dt>'."\n"; - echo "\t\t\t\t".'<dd><span><a href="moderate.php?fid='.$forum_id.'&tid='.$id.'&p='.$p.'">'.$lang_common['Moderate topic'].'</a></span></dd>'."\n"; + echo "\t\t\t\t".'<dd><span><a href="moderate.php?fid='.$forum_id.'&tid='.$id.'&p='.$p.'">'.$lang_common['Moderate topic'].'</a>'.($num_pages > 1 ? ' (<a href="moderate.php?fid='.$forum_id.'&tid='.$id.'&action=all">'.$lang_common['All'].'</a>)' : '').'</span></dd>'."\n"; echo "\t\t\t\t".'<dd><span><a href="moderate.php?fid='.$forum_id.'&move_topics='.$id.'">'.$lang_common['Move topic'].'</a></span></dd>'."\n"; if ($cur_topic['closed'] == '1') diff --git a/include/cache.php b/include/cache.php index cb21264..71111b1 100644 --- a/include/cache.php +++ b/include/cache.php @@ -108,7 +108,7 @@ function generate_quickjump_cache($group_id = false) $output .= "\t\t\t\t\t\t\t".'<option value="'.$cur_forum['fid'].'"<?php echo ($forum_id == '.$cur_forum['fid'].') ? \' selected="selected"\' : \'\' ?>>'.pun_htmlspecialchars($cur_forum['forum_name']).$redirect_tag.'</option>'."\n"; } - $output .= "\t\t\t\t\t\t".'</optgroup>'."\n\t\t\t\t\t".'</select>'."\n\t\t\t\t\t".'<input type="submit" value="<?php echo $lang_common[\'Go\'] ?>" accesskey="g" />'."\n\t\t\t\t\t".'</label></div>'."\n\t\t\t\t".'</form>'."\n"; + $output .= "\t\t\t\t\t\t".'</optgroup>'."\n\t\t\t\t\t".'</select></label>'."\n\t\t\t\t\t".'<input type="submit" value="<?php echo $lang_common[\'Go\'] ?>" accesskey="g" />'."\n\t\t\t\t\t".'</div>'."\n\t\t\t\t".'</form>'."\n"; } } diff --git a/include/common.php b/include/common.php index 1579222..ab61a7c 100644 --- a/include/common.php +++ b/include/common.php @@ -10,7 +10,7 @@ if (!defined('PUN_ROOT')) exit('The constant PUN_ROOT must be defined and point to a valid FluxBB installation root directory.'); // Define the version and database revision that this code was written for -define('FORUM_VERSION', '1.5.5'); +define('FORUM_VERSION', '1.5.6'); define('FORUM_DB_REVISION', 20); define('FORUM_SI_REVISION', 2); diff --git a/include/functions.php b/include/functions.php index 3f6282c..3956d25 100644 --- a/include/functions.php +++ b/include/functions.php @@ -454,7 +454,7 @@ function check_username($username, $exclude_id = null) global $db, $pun_config, $errors, $lang_prof_reg, $lang_register, $lang_common, $pun_bans; // Include UTF-8 function - require PUN_ROOT.'include/utf8/strcasecmp.php'; + require_once PUN_ROOT.'include/utf8/strcasecmp.php'; // Convert multiple whitespace characters into one (to prevent people from registering with indistinguishable usernames) $username = preg_replace('%\s+%s', ' ', $username); @@ -616,6 +616,9 @@ function generate_page_title($page_title, $p = null) { global $pun_config, $lang_common; + if (!is_array($page_title)) + $page_title = array($page_title); + $page_title = array_reverse($page_title); if (!is_null($p)) @@ -1061,10 +1064,13 @@ function random_key($len, $readable = false, $hash = false) // // Make sure that HTTP_REFERER matches base_url/script // -function confirm_referrer($script, $error_msg = false) +function confirm_referrer($scripts, $error_msg = false) { global $pun_config, $lang_common; + if (!is_array($scripts)) + $scripts = array($scripts); + // There is no referrer if (empty($_SERVER['HTTP_REFERER'])) message($error_msg ? $error_msg : $lang_common['Bad referrer']); @@ -1074,13 +1080,20 @@ function confirm_referrer($script, $error_msg = false) if (strpos($referrer['host'], 'www.') === 0) $referrer['host'] = substr($referrer['host'], 4); - $valid = parse_url(strtolower(get_base_url().'/'.$script)); - // Remove www subdomain if it exists - if (strpos($valid['host'], 'www.') === 0) - $valid['host'] = substr($valid['host'], 4); + $valid_paths = array(); + foreach ($scripts as $script) + { + $valid = parse_url(strtolower(get_base_url().'/'.$script)); + // Remove www subdomain if it exists + if (strpos($valid['host'], 'www.') === 0) + $valid['host'] = substr($valid['host'], 4); + + $valid_host = $valid['host']; + $valid_paths[] = $valid['path']; + } // Check the host and path match. Ignore the scheme, port, etc. - if ($referrer['host'] != $valid['host'] || $referrer['path'] != $valid['path']) + if ($referrer['host'] != $valid_host || !in_array($referrer['path'], $valid_paths)) message($error_msg ? $error_msg : $lang_common['Bad referrer']); } @@ -2095,7 +2108,7 @@ function display_saved_queries() <h2><span><?php echo $lang_common['Debug table'] ?></span></h2> <div class="box"> <div class="inbox"> - <table cellspacing="0"> + <table> <thead> <tr> <th class="tcl" scope="col"><?php echo $lang_common['Query times'] ?></th> diff --git a/index.php b/index.php index 5a6a9a0..6faf61a 100644 --- a/index.php +++ b/index.php @@ -68,7 +68,7 @@ while ($cur_forum = $db->fetch_assoc($result)) <h2><span><?php echo pun_htmlspecialchars($cur_forum['cat_name']) ?></span></h2> <div class="box"> <div class="inbox"> - <table cellspacing="0"> + <table> <thead> <tr> <th class="tcl" scope="col"><?php echo $lang_common['Forum'] ?></th> diff --git a/install.php b/install.php index c2e72de..056545b 100644 --- a/install.php +++ b/install.php @@ -7,7 +7,7 @@ */ // The FluxBB version this script installs -define('FORUM_VERSION', '1.5.5'); +define('FORUM_VERSION', '1.5.6'); define('FORUM_DB_REVISION', 20); define('FORUM_SI_REVISION', 2); diff --git a/lang/English/common.php b/lang/English/common.php index ceb765f..35cd450 100644 --- a/lang/English/common.php +++ b/lang/English/common.php @@ -124,6 +124,7 @@ $lang_common = array( 'Jump to' => 'Jump to', 'Go' => ' Go ', // Submit button in forum jump 'Moderate topic' => 'Moderate topic', +'All' => 'All', 'Move topic' => 'Move topic', 'Open topic' => 'Open topic', 'Close topic' => 'Close topic', diff --git a/misc.php b/misc.php index 4909e61..a758892 100644 --- a/misc.php +++ b/misc.php @@ -216,6 +216,9 @@ else if (isset($_GET['report'])) if (isset($_POST['form_sent'])) { + // Make sure they got here from the site + confirm_referrer('misc.php'); + // Clean up reason from POST $reason = pun_linebreaks(pun_trim($_POST['req_reason'])); if ($reason == '') diff --git a/moderate.php b/moderate.php index 8464a26..cbfff2a 100644 --- a/moderate.php +++ b/moderate.php @@ -278,6 +278,8 @@ if (isset($_GET['tid'])) // Used to disable the Move and Delete buttons if there are no replies to this topic $button_status = ($cur_topic['num_replies'] == 0) ? ' disabled="disabled"' : ''; + if (isset($_GET['action']) && $_GET['action'] == 'all') + $pun_user['disp_posts'] = $cur_topic['num_replies'] + 1; // Determine the post offset (based on $_GET['p']) $num_pages = ceil(($cur_topic['num_replies'] + 1) / $pun_user['disp_posts']); @@ -859,7 +861,7 @@ require PUN_ROOT.'header.php'; <h2><span><?php echo pun_htmlspecialchars($cur_forum['forum_name']) ?></span></h2> <div class="box"> <div class="inbox"> - <table cellspacing="0"> + <table> <thead> <tr> <th class="tcl" scope="col"><?php echo $lang_common['Topic'] ?></th> diff --git a/post.php b/post.php index 6f433df..8d0ee2a 100644 --- a/post.php +++ b/post.php @@ -63,6 +63,9 @@ if (isset($_POST['form_sent'])) if (!isset($_POST['preview']) && $pun_user['last_post'] != '' && (time() - $pun_user['last_post']) < $pun_user['g_post_flood']) $errors[] = sprintf($lang_post['Flood start'], $pun_user['g_post_flood'], $pun_user['g_post_flood'] - (time() - $pun_user['last_post'])); + // Make sure they got here from the site + confirm_referrer(array('post.php', 'viewtopic.php')); + // If it's a new topic if ($fid) { @@ -547,6 +550,8 @@ require PUN_ROOT.'header.php'; <ul class="crumbs"> <li><a href="index.php"><?php echo $lang_common['Index'] ?></a></li> <li><span>» </span><a href="viewforum.php?id=<?php echo $cur_posting['id'] ?>"><?php echo pun_htmlspecialchars($cur_posting['forum_name']) ?></a></li> +<?php if (isset($_POST['req_subject'])): ?> <li><span>» </span><?php echo pun_htmlspecialchars($_POST['req_subject']) ?></li> +<?php endif; ?> <?php if (isset($cur_posting['subject'])): ?> <li><span>» </span><a href="viewtopic.php?id=<?php echo $tid ?>"><?php echo pun_htmlspecialchars($cur_posting['subject']) ?></a></li> <?php endif; ?> <li><span>» </span><strong><?php echo $action ?></strong></li> </ul> diff --git a/profile.php b/profile.php index 679163d..ce4e6dc 100644 --- a/profile.php +++ b/profile.php @@ -81,8 +81,8 @@ if ($action == 'change_pass') if (isset($_POST['form_sent'])) { - if ($pun_user['is_admmod']) - confirm_referrer('profile.php'); + // Make sure they got here from the site + confirm_referrer('profile.php'); $old_password = isset($_POST['req_old_password']) ? pun_trim($_POST['req_old_password']) : ''; $new_password1 = pun_trim($_POST['req_new_password1']); @@ -195,6 +195,9 @@ else if ($action == 'change_email') { if (pun_hash($_POST['req_password']) !== $pun_user['password']) message($lang_profile['Wrong pass']); + + // Make sure they got here from the site + confirm_referrer('profile.php'); require PUN_ROOT.'include/email.php'; @@ -322,6 +325,9 @@ else if ($action == 'upload_avatar' || $action == 'upload_avatar2') { if (!isset($_FILES['req_file'])) message($lang_profile['No file']); + + // Make sure they got here from the site + confirm_referrer('profile.php'); $uploaded_file = $_FILES['req_file']; @@ -700,8 +706,8 @@ else if (isset($_POST['form_sent'])) $is_moderator)))) // or the user is another mod message($lang_common['No permission'], false, '403 Forbidden'); - if ($pun_user['is_admmod']) - confirm_referrer('profile.php'); + // Make sure they got here from the site + confirm_referrer('profile.php'); $username_updated = false; diff --git a/search.php b/search.php index 4ec74ca..db0d527 100644 --- a/search.php +++ b/search.php @@ -577,7 +577,7 @@ if (isset($_GET['action']) || isset($_GET['search_id'])) <h2><span><?php echo $lang_search['Search results'] ?></span></h2> <div class="box"> <div class="inbox"> - <table cellspacing="0"> + <table> <thead> <tr> <th class="tcl" scope="col"><?php echo $lang_common['Topic'] ?></th> diff --git a/style/Air.css b/style/Air.css index 0c0c163..f4f053a 100644 --- a/style/Air.css +++ b/style/Air.css @@ -1187,6 +1187,10 @@ MAIN FORMS width: 98%; } +.pun textarea { + resize: vertical; +} + .pun #quickpost .txtarea { padding-right: 12px; position: relative; diff --git a/style/Earth.css b/style/Earth.css index f520ea9..0943457 100644 --- a/style/Earth.css +++ b/style/Earth.css @@ -1186,6 +1186,10 @@ MAIN FORMS width: 98%; } +.pun textarea { + resize: vertical; +} + .pun #quickpost .txtarea { padding-right: 12px; position: relative; diff --git a/style/Fire.css b/style/Fire.css index 702363d..de952e3 100644 --- a/style/Fire.css +++ b/style/Fire.css @@ -1186,6 +1186,10 @@ MAIN FORMS width: 98%; } +.pun textarea { + resize: vertical; +} + .pun #quickpost .txtarea { padding-right: 12px; position: relative; diff --git a/userlist.php b/userlist.php index 0f1480d..774bcef 100644 --- a/userlist.php +++ b/userlist.php @@ -122,7 +122,7 @@ while ($cur_group = $db->fetch_assoc($result)) <h2><span><?php echo $lang_common['User list'] ?></span></h2> <div class="box"> <div class="inbox"> - <table cellspacing="0"> + <table> <thead> <tr> <th class="tcl" scope="col"><?php echo $lang_common['Username'] ?></th> diff --git a/viewforum.php b/viewforum.php index e562376..04ff112 100644 --- a/viewforum.php +++ b/viewforum.php @@ -122,7 +122,7 @@ require PUN_ROOT.'header.php'; <h2><span><?php echo pun_htmlspecialchars($cur_forum['forum_name']) ?></span></h2> <div class="box"> <div class="inbox"> - <table cellspacing="0"> + <table> <thead> <tr> <th class="tcl" scope="col"><?php echo $lang_common['Topic'] ?></th> @@ -141,12 +141,9 @@ $result = $db->query('SELECT id FROM '.$db->prefix.'topics WHERE forum_id='.$id. if ($db->num_rows($result)) { $topic_ids = array(); - for ($i = 0;$cur_topic_id = $db->result($result, $i);$i++) + for ($i = 0; $cur_topic_id = $db->result($result, $i); $i++) $topic_ids[] = $cur_topic_id; - if (empty($topic_ids)) - error('The topic table and forum table seem to be out of sync!', __FILE__, __LINE__); - // Fetch list of topics to display on this page if ($pun_user['is_guest'] || $pun_config['o_show_dot'] == '0') { -- To stop receiving notification emails like this one, please contact the administrator of this repository. _______________________________________________ Xfce4-commits mailing list Xfce4-commits@xfce.org https://mail.xfce.org/mailman/listinfo/xfce4-commits