Function __global->can_email_address
Definitions
sources/mail2.php
- Find if an e-mail address can be e-mailed.
- Visibility: public
- Is abstract?: No
- Is static?: No
- Is final?: No
- Returns: bool
Parameters
| Name | Type | Passed by reference? | Variadic? | Default | Set | Range | Description |
|---|---|---|---|---|---|---|---|
| $email_address | No | No | required parameter | N/A | N/A | The e-mail address | |
| $host | ?string | No | No | Null | N/A | N/A | The server hostname (null: use configured) |
| $port | ?integer | No | No | Null | N/A | N/A | The port (null: use configured) |
| $type | ?string | No | No | Null | imap imaps imaps_nocert pop3 pop3s pop3s_nocert | N/A | The protocol (null: use configured / autodetect) |
| $folder | ?string | No | No | Null | N/A | N/A | The inbox identifier (null: use configured) |
| $username | ?string | No | No | Null | N/A | N/A | The username (null: use configured) |
| $password | ?string | No | No | Null | N/A | N/A | The password (null: use configured) |
Returns
- Whether this address can be e-mailed
- Type: boolean
- Set: N/A
- Range: N/A
Preview
Code (PHP)
/**
* Find if an e-mail address can be e-mailed.
*
* @param EMAIL $email_address The e-mail address
* @param ?string $host The server hostname (null: use configured)
* @param ?integer $port The port (null: use configured)
* @param ?string $type The protocol (null: use configured / autodetect)
* @set imap imaps imaps_nocert pop3 pop3s pop3s_nocert
* @param ?string $folder The inbox identifier (null: use configured)
* @param ?string $username The username (null: use configured)
* @param ?string $password The password (null: use configured)
* @return boolean Whether this address can be e-mailed
*/
function can_email_address(string $email_address, ?string $host = null, ?int $port = null, ?string $type = null, ?string $folder = null, ?string $username = null, ?string $password = null) : bool
* Find if an e-mail address can be e-mailed.
*
* @param EMAIL $email_address The e-mail address
* @param ?string $host The server hostname (null: use configured)
* @param ?integer $port The port (null: use configured)
* @param ?string $type The protocol (null: use configured / autodetect)
* @set imap imaps imaps_nocert pop3 pop3s pop3s_nocert
* @param ?string $folder The inbox identifier (null: use configured)
* @param ?string $username The username (null: use configured)
* @param ?string $password The password (null: use configured)
* @return boolean Whether this address can be e-mailed
*/
function can_email_address(string $email_address, ?string $host = null, ?int $port = null, ?string $type = null, ?string $folder = null, ?string $username = null, ?string $password = null) : bool

