mirror of
https://github.com/phpbb/phpbb.git
synced 2025-01-19 07:08:09 +01:00
Slightly fairer sig length check, removes =.*? from BBCode and HTML tags
git-svn-id: file:///svn/phpbb/trunk@1360 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
parent
a3014676ca
commit
9aa55fb94c
@ -631,7 +631,16 @@ if( isset($HTTP_GET_VARS['mode']) || isset($HTTP_POST_VARS['mode']) )
|
||||
|
||||
if( $signature != "" )
|
||||
{
|
||||
if( strlen($signature) > $board_config['max_sig_chars'] )
|
||||
$sig_length_check = preg_replace("/(\[.*?)(=.*?)\]/is", "\\1]", $signature);
|
||||
if( $allowhtml )
|
||||
{
|
||||
$sig_length_check = preg_replace("/(<.*?)(=.*?)([ \/]?" . ">)/is", "\\1\\3", $signature);
|
||||
}
|
||||
|
||||
$signature_bbcode_uid = ( $allowbbcode ) ? make_bbcode_uid() : "";
|
||||
$signature = prepare_message($signature, $allowhtml, $allowbbcode, $allowsmilies, $signature_bbcode_uid);
|
||||
|
||||
if( strlen($sig_length_check) > $board_config['max_sig_chars'] )
|
||||
{
|
||||
$error = TRUE;
|
||||
if( isset($error_msg) )
|
||||
@ -640,11 +649,6 @@ if( isset($HTTP_GET_VARS['mode']) || isset($HTTP_POST_VARS['mode']) )
|
||||
}
|
||||
$error_msg .= $lang['Signature_too_long'];
|
||||
}
|
||||
else
|
||||
{
|
||||
$signature_bbcode_uid = ( $allowbbcode ) ? make_bbcode_uid() : "";
|
||||
$signature = prepare_message($signature, $allowhtml, $allowbbcode, $allowsmilies, $signature_bbcode_uid);
|
||||
}
|
||||
}
|
||||
|
||||
if( $mode == "register" )
|
||||
|
Loading…
x
Reference in New Issue
Block a user