diff --git a/phpBB/includes/auth.php b/phpBB/includes/auth.php index 0f51a73b0a..fe8cb16eaf 100644 --- a/phpBB/includes/auth.php +++ b/phpBB/includes/auth.php @@ -200,7 +200,7 @@ function auth($type, $forum_id, $userdata, $f_access = '') { case AUTH_ALL: $auth_user[$key] = TRUE; - $auth_user[$key . '_type'] = $lang['Auth_Anonymous_users']; + $auth_user[$key . '_type'] = $lang['Auth_Anonymous_Users']; break; case AUTH_REG: @@ -239,7 +239,7 @@ function auth($type, $forum_id, $userdata, $f_access = '') { case AUTH_ALL: $auth_user[$f_forum_id][$key] = TRUE; - $auth_user[$f_forum_id][$key . '_type'] = $lang['Auth_Anonymous_users']; + $auth_user[$f_forum_id][$key . '_type'] = $lang['Auth_Anonymous_Users']; break; case AUTH_REG: diff --git a/phpBB/includes/bbcode.php b/phpBB/includes/bbcode.php index 3fce5f4798..f2c6d7be96 100644 --- a/phpBB/includes/bbcode.php +++ b/phpBB/includes/bbcode.php @@ -734,34 +734,39 @@ function bbcode_array_pop(&$stack) // function smilies_pass($message) { - static $orig, $repl; + static $orig, $repl; - if (!isset($orig)) - { - global $db, $board_config; - $orig = $repl = array(); + if (!isset($orig)) + { + global $db, $board_config; + $orig = $repl = array(); - $sql = 'SELECT code, smile_url FROM ' . SMILIES_TABLE; - if( !$result = $db->sql_query($sql) ) - { - message_die(GENERAL_ERROR, "Couldn't obtain smilies data", "", __LINE__, __FILE__, $sql); - } - $smilies = $db->sql_fetchrowset($result); + $sql = 'SELECT code, smile_url FROM ' . SMILIES_TABLE; + if( !$result = $db->sql_query($sql) ) + { + message_die(GENERAL_ERROR, "Couldn't obtain smilies data", "", __LINE__, __FILE__, $sql); + } + $smilies = $db->sql_fetchrowset($result); - usort($smilies, 'smiley_sort'); - for($i = 0; $i < count($smilies); $i++) - { - $orig[] = "/(?<=.\W|\W.|^\W)" . phpbb_preg_quote($smilies[$i]['code'], "/") . "(?=.\W|\W.|\W$)/"; - $repl[] = '' . $smilies[$i]['smile_url'] . ''; - } - } + if (count($smilies)) + { + usort($smilies, 'smiley_sort'); + } - if (count($orig)) - { - $message = preg_replace($orig, $repl, ' ' . $message . ' '); - $message = substr($message, 1, -1); - } - return $message; + for ($i = 0; $i < count($smilies); $i++) + { + $orig[] = "/(?<=.\W|\W.|^\W)" . phpbb_preg_quote($smilies[$i]['code'], "/") . "(?=.\W|\W.|\W$)/"; + $repl[] = '' . $smilies[$i]['smile_url'] . ''; + } + } + + if (count($orig)) + { + $message = preg_replace($orig, $repl, ' ' . $message . ' '); + $message = substr($message, 1, -1); + } + + return $message; } function smiley_sort($a, $b) @@ -774,5 +779,4 @@ function smiley_sort($a, $b) return ( strlen($a['code']) > strlen($b['code']) ) ? -1 : 1; } - -?> +?> \ No newline at end of file diff --git a/phpBB/includes/functions_validate.php b/phpBB/includes/functions_validate.php index efc9cbcfd9..a1c771b351 100644 --- a/phpBB/includes/functions_validate.php +++ b/phpBB/includes/functions_validate.php @@ -117,7 +117,7 @@ function validate_email($email) if ($email != '') { - if (preg_match('/^[a-z0-9\.\-_\+]+@[a-z0-9\-_]+\.([a-z0-9\-_]+\.)*?[a-z]+$/is', $email)) + if (preg_match('/^[a-z0-9&.-_+]+@[a-z0-9\-_]+\.([a-z0-9\-_]+\.)*?[a-z]+$/is', $email)) { $sql = "SELECT ban_email FROM " . BANLIST_TABLE; diff --git a/phpBB/install/install.php b/phpBB/install/install.php index fa823494b0..d8866c8c33 100644 --- a/phpBB/install/install.php +++ b/phpBB/install/install.php @@ -99,7 +99,7 @@ function page_common_form($hidden, $submit) ?> - + - + - + assign_vars(array( - 'PAGINATION' => generate_pagination("modcp.$phpEx?" . POST_FORUM_URL . "=$forum_id", $forum_topics, $board_config['topics_per_page'], $start), + 'PAGINATION' => generate_pagination("modcp.$phpEx?" . POST_FORUM_URL . "=$forum_id&sid=" . $userdata['session_id'], $forum_topics, $board_config['topics_per_page'], $start), 'PAGE_NUMBER' => sprintf($lang['Page_of'], ( floor( $start / $board_config['topics_per_page'] ) + 1 ), ceil( $forum_topics / $board_config['topics_per_page'] )), 'L_GOTO_PAGE' => $lang['Goto_page']) ); diff --git a/phpBB/templates/subSilver/admin/user_select_body.tpl b/phpBB/templates/subSilver/admin/user_select_body.tpl index 0705e624cf..5d7a31b83c 100644 --- a/phpBB/templates/subSilver/admin/user_select_body.tpl +++ b/phpBB/templates/subSilver/admin/user_select_body.tpl @@ -8,6 +8,6 @@ {L_USER_SELECT} - {S_HIDDEN_FIELDS} + {S_HIDDEN_FIELDS} diff --git a/phpBB/templates/subSilver/memberlist_body.tpl b/phpBB/templates/subSilver/memberlist_body.tpl index 6f1523c00d..af1340d8cd 100644 --- a/phpBB/templates/subSilver/memberlist_body.tpl +++ b/phpBB/templates/subSilver/memberlist_body.tpl @@ -32,7 +32,7 @@ -   +   diff --git a/phpBB/viewtopic.php b/phpBB/viewtopic.php index 2d1daa21ba..d30f2b11b1 100644 --- a/phpBB/viewtopic.php +++ b/phpBB/viewtopic.php @@ -615,7 +615,7 @@ if ( $can_watch_topic ) // If we've got a hightlight set pass it on to pagination, // I get annoyed when I lose my highlight after the first page. // -$pagination = ( $highlight_active ) ? generate_pagination("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id&postdays=$post_days&postorder=$post_order&highlight=$highlight", $total_replies, $board_config['posts_per_page'], $start) : generate_pagination("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id&postdays=$post_days&postorder=$post_order", $total_replies, $board_config['posts_per_page'], $start); +$pagination = ( $highlight != '' ) ? generate_pagination("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id&postdays=$post_days&postorder=$post_order&highlight=$highlight", $total_replies, $board_config['posts_per_page'], $start) : generate_pagination("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id&postdays=$post_days&postorder=$post_order", $total_replies, $board_config['posts_per_page'], $start); // // Send vars to template