issue 2119. supporting php 5.4. modules and widgets.

git-svn-id: http://xe-core.googlecode.com/svn/branches/maserati@12706 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
flyskyko 2013-02-05 09:45:04 +00:00
parent ff75082eee
commit 8a7c28babc
90 changed files with 572 additions and 83 deletions

View file

@ -147,13 +147,13 @@ class spamfilterController extends spamfilter
*/
function insertIP($ipaddress_list, $description = null)
{
print_r($ipaddress_list);
$regExr = "/^((\d{1,3}(?:.(\d{1,3}|\*)){3})\s*(\/\/(.*)\s*)?)*\s*$/";
if(!preg_match($regExr,$ipaddress_list)) return new Object(-1, 'msg_invalid');
$ipaddress_list = str_replace("\r","",$ipaddress_list);
$ipaddress_list = explode("\n",$ipaddress_list);
foreach($ipaddress_list as $ipaddressValue)
{
$args = new stdClass();
preg_match("/(\d{1,3}(?:.(\d{1,3}|\*)){3})\s*(\/\/(.*)\s*)?/",$ipaddressValue,$matches);
if($ipaddress=trim($matches[1]))
{