Пример #1
0
 /**
  * List available scripts on the SIEVE server.
  *
  * This function returns true or false.  $sieve->response will be filled
  * with the names of the scripts found.  If a script is active, the
  * $sieve->response["ACTIVE"] will contain the name of the active script.
  *
  * @return boolean
  */
 function sieve_listscripts()
 {
     $this->__fputs('LISTSCRIPTS');
     sieve::get_response();
     //should always return true, even if there are no scripts...
     if (isset($this->found_script) and $this->found_script) {
         return true;
     } else {
         $this->error = EC_NOSCRIPTS;
         //sieve::getresponse has no way of telling wether a script was found...
         $this->error_raw = "No scripts found for this account.";
         return false;
     }
 }