
11-06-2014, 10:10 PM
|
 |
|
|
Join Date: Apr 2009
Posts: 47
Благодарил(а): 0 раз(а)
Поблагодарили:
0 раз(а) в 0 сообщениях
|
|
Quote:
Originally Posted by AusPhotography
Just upgraded to PHP 5.4 and the edit rules does not work 
The edit window is empty
This change fixed it... (adding ,ENT_COMPAT | ENT_HTML401,"ISO-8859-1" to the htmlspecialchars call -- don't know why it works??
See: http://docs.php.net/manual/en/functi...ecialchars.php
PHP Code:
if (($_REQUEST['do'] == 'vsaafr_addedit') AND $vbulletin->userinfo['userid'] AND is_member_of($vbulletin->userinfo,6))
{
$vsafr_getrule_set = $vbulletin->input->clean_gpc('r', 'cfrset', TYPE_UINT);
if ($vsafr_getrule_set>0)
{
$vbulletin->db->hide_errors();
$vsafr_getrule = $vbulletin->db->query_first("
SELECT id, name, rules
FROM " . TABLE_PREFIX . "vsa_frules AS vsa_frules
WHERE id = '" . $vbulletin->db->escape_string($vsafr_getrule_set) . "'
");
$vsafr_getrule['name'] = htmlspecialchars($vsafr_getrule['name'],ENT_COMPAT | ENT_HTML401,"ISO-8859-1");
$vsafr_getrule['rules'] = htmlspecialchars($vsafr_getrule['rules'],ENT_COMPAT | ENT_HTML401,"ISO-8859-1");
$vbulletin->db->show_errors();
}
Edit: The two htmlspecialchars would seem to be pointless anyway
|
Thanks, this solved my problem.
|