libraries/tbs/examples/class.phpmailer.php
function MailSend($header, $body) {
        $to = "";
        for($i = 0; $i < count($this->to); $i++)
        {
            if($i != 0) { $to .= ", "; }
            $to .= $this->to[$i][0];
        }

        if ($this->Sender != "" && strlen(ini_get("safe_mode"))< 1)
        {
            $old_from = ini_get("sendmail_from");
            ini_set("sendmail_from", $this->Sender);
            $params = sprintf("-oi -f %s", $this->Sender);
            $rt = @mail($to, $this->EncodeHeader($this->Subject), $body, 
                        $header, $params);
        }
        else
            $rt = @mail($to, $this->EncodeHeader($this->Subject), $body, $header);

        if (isset($old_from))
            ini_set("sendmail_from", $old_from);

        if(!$rt)
        {
            $this->SetError($this->Lang("instantiate"));
            return false;
        }

        return true;
    }
function MailSend($header, $body) {
        $to = "";
        for($i = 0; $i < count($this->to); $i++)
        {
            if($i != 0) { $to .= ", "; }
            $to .= $this->to[$i][0];
        }

        if ($this->Sender != "" && strlen(ini_get("safe_mode"))< 1)
        {
            $old_from = ini_get("sendmail_from");
            ini_set("sendmail_from", $this->Sender);
            $params = sprintf("-oi -f %s", $this->Sender);
            $rt = @mail($to, $this->EncodeHeader($this->Subject), $body, 
                        $header, $params);
        }
        else
            $rt = @mail($to, $this->EncodeHeader($this->Subject), $body, $header);

        if (isset($old_from))
            ini_set("sendmail_from", $old_from);

        if(!$rt)
        {
            $this->SetError($this->Lang("instantiate"));
            return false;
        }

        return true;
    }
function MailSend ( $ header , $ body ) { $ to = "" ; for ( $ i = 0 ; $ i < count ( $ this -> to ) ; $ i ++ ) { if ( $ i != 0 ) { $ to .= ", " ; } $ to .= $ this -> to [ $ i ] [ 0 ] ; } if ( $ this -> Sender != "" && strlen ( ini_get ( "safe_mode" ) ) < 1 ) { $ old_from = ini_get ( "sendmail_from" ) ; ini_set ( "sendmail_from" , $ this -> Sender ) ; $ params = sprintf ( "-oi -f %s" , $ this -> Sender ) ; $ rt = @ mail ( $ to , $ this -> EncodeHeader ( $ this -> Subject ) , $ body , $ header , $ params ) ; } else $ rt = @ mail ( $ to , $ this -> EncodeHeader ( $ this -> Subject ) , $ body , $ header ) ; if ( isset ( $ old_from ) ) ini_set ( "sendmail_from" , $ old_from ) ; if ( ! $ rt ) { $ this -> SetError ( $ this -> Lang ( "instantiate" ) ) ; return false ; } return true ; }
Sends mail using the PHP mail() function.
@access private
@return bool
Sends mail using the PHP mail () function .