public function addrFormat($addr)
    {
        if (empty($addr[1])) { // No name provided
            return $this->secureHeader($addr[0]);
        } else {
            return $this->encodeHeader($this->secureHeader($addr[1]), 'phrase') . ' <' . $this->secureHeader(
                $addr[0]
            ) . '>';
        }
    }
public function addrFormat($addr)
    {
        if (empty($addr[1])) { // No name provided
            return $this->secureHeader($addr[0]);
        } else {
            return $this->encodeHeader($this->secureHeader($addr[1]), 'phrase') . ' <' . $this->secureHeader(
                $addr[0]
            ) . '>';
        }
    }
public function addrFormat ( $ addr ) { if ( empty ( $ addr [ 1 ] ) ) { // No name provided return $ this -> secureHeader ( $ addr [ 0 ] ) ; } else { return $ this -> encodeHeader ( $ this -> secureHeader ( $ addr [ 1 ] ) , 'phrase' ) . ' <' . $ this -> secureHeader ( $ addr [ 0 ] ) . '>' ; } }
Format an address for use in a message header.
@access public
@param array $addr A 2-element indexed array, element 0 containing an address, element 1 containing a name
like array('joe@example.com', 'Joe User')
@return string
Format an address for use in a message header .