api posting with htmlstatus fails if it doesn't contain any html tags issue #104

This commit is contained in:
redmatrix 2015-10-27 21:16:59 -07:00
parent 65587be737
commit 07c0bc7b04

View File

@ -826,6 +826,7 @@ require_once('include/attach.php');
require_once('include/html2bbcode.php');
$txt = requestdata('htmlstatus');
if((strpos($txt,'<') !== false) || (strpos($txt,'>') !== false)) {
$txt = html2bb_video($txt);
@ -837,9 +838,10 @@ require_once('include/attach.php');
$purifier = new HTMLPurifier($config);
$txt = $purifier->purify($txt);
$_REQUEST['body'] = html2bbcode($txt);
}
$_REQUEST['body'] = html2bbcode($txt);
}
else
$_REQUEST['body'] = requestdata('status');