PHP Deprecated error

Issue #4 resolved
János Csárdi-Braunstein created an issue

I use PHP 5.3 (because php 5.2 is not supported), and i see these error (?) message:

{{{ PHP Deprecated: Call-time pass-by-reference has been deprecated in /var/www/XXX/model/audit/audit.php on line 32 PHP Deprecated: Call-time pass-by-reference has been deprecated in /var/www/XXX/model/audit/audit.php on line 36 PHP Deprecated: Call-time pass-by-reference has been deprecated in /var/www/XXX/model/audit/audit.php on line 40 }}}

Comments (3)

  1. Janos SUTO repo owner

    try the following fix (I will commit it soon to the source tree):

    --- a/webui/model/audit/audit.php
    +++ b/webui/model/audit/audit.php
    @@ -29,15 +29,15 @@ class ModelAuditAudit extends Model {
           }
     
           if(isset($data['ipaddr'])) {
    -         $where .= " AND ipaddr IN (" . $this->append_search_criteria($data['ipaddr'], &$arr) . ")";
    +         $where .= " AND ipaddr IN (" . $this->append_search_criteria($data['ipaddr'], $arr) . ")";
           }
     
           if(isset($data['user'])) {
    -         $where .= " AND email IN (" . $this->append_search_criteria($data['user'], &$arr) . ")";
    +         $where .= " AND email IN (" . $this->append_search_criteria($data['user'], $arr) . ")";
           }
     
           if(isset($data['ref'])) {
    -         $where .= " AND ref IN (" . $this->append_search_criteria($data['ref'], &$arr) . ")";
    +         $where .= " AND ref IN (" . $this->append_search_criteria($data['ref'], $arr) . ")";
           }
     
     
    @@ -98,7 +98,7 @@ class ModelAuditAudit extends Model {
        }
     
    

    - private function append_search_criteria($s = '', $arr = array()) { + private function append_search_criteria($s = '', &$arr = array()) { $q = "";

    $a = explode("*", $s);

  2. Log in to comment