Добавляется проверка при создании темы и при ответе в теме:
В файле: /engine/bullet_energy/action/site/newpost.phpНайти:
$option['message'] = parent::$db->safesql($this->filter->BB_Parse($this->filter-&
gt;process(trim($_REQUEST['text_msg'])), false)) ;
Добавить выше:
// do not get mad
preg_match_all( '/\[(b|i|u|s|center|hide|left|right|code|color=([^\]]+)|li
st|ol=([^\]]+))]/is' , $_REQUEST['text_msg'], $count_start_tag );
preg_match_all( '/\[\/(b|i|u|s|center|hide|left|right|code|color|list|ol)]/is'
, $_REQUEST['text_msg'], $count_end_tag );
if( count($count_start_tag[0]) != count($count_end_tag[0]) ) {
die(parent::$helper->getJson(array('param' => '0', 'data' => parent::$bullet_energy_lang['error_21']))) ;
}
//
Далее найти:
$row['post'] = $this->filter->BB_Parse(trim($this->filter->process($row['po
st'])), false) ;
Добавить выше:
// do not get mad
preg_match_all( '/\[(b|i|u|s|center|hide|left|right|code|color=([^\]]+)|li
st|ol=([^\]]+))]/is' , $row['post'], $count_start_tag );
preg_match_all( '/\[\/(b|i|u|s|center|hide|left|right|code|color|list|ol)]/is'
, $row['post'], $count_end_tag );
if( count($count_start_tag[0]) != count($count_end_tag[0]) ) {
return parent::$helper->getError(parent::$bullet_energy_lang[
9;error_21']) ;
}
//
В файле: /engine/bullet_energy/action/site/newtopic.phpНайти:
$post = stripslashes($filter->BB_Parse($filter->process(parent::$helper-&g
t;convert_unicode($_POST['data'], parent::$config['DLE']['charset'])), false)) ;
Добавить выше:
// do not get mad
preg_match_all( '/\[(b|i|u|s|center|hide|left|right|code|color=([^\]]+)|li
st|ol=([^\]]+))]/is' , $_POST['data'], $count_start_tag );
preg_match_all( '/\[\/(b|i|u|s|center|hide|left|right|code|color|list|ol)]/is'
, $_POST['data'], $count_end_tag );
if( count($count_start_tag[0]) != count($count_end_tag[0]) ) {
return parent::$helper->getJson(array(
'data' => parent::$bullet_energy_lang['error_21'],
'param' => 0,
'titl' => '')) ;
}
//
Найти:
$option['topicOneMessage'] = parent::$db->safesql($filter->BB_Parse($filter->process($_POST&
#91;'message_new_topic']), false)) ;
Добавить выше:
// do not get mad
preg_match_all( '/\[(b|i|u|s|center|hide|left|right|code|color=([^\]]+)|li
st|ol=([^\]]+))]/is' , $_POST['message_new_topic'], $count_start_tag );
preg_match_all( '/\[\/(b|i|u|s|center|hide|left|right|code|color|list|ol)]/is'
, $_POST['message_new_topic'], $count_end_tag );
if( count($count_start_tag[0]) != count($count_end_tag[0]) ) {
$this->_param['error'][] = parent::$bullet_energy_lang['error_21'] ;
}
//
В файле: /engine/bullet_energy/library/language/windows-1251/Russian/site.lngНайти:
'error_20' => 'Загрузка файлов этого типа запрещена',
Добавить ниже:
/**/
'error_21' => 'Сообщение содержит незакрытые теги',
, нравится это сообщение.