Function __global->_imap_server_spec

Definitions

sources/mail2.php

  • Get an IMAP/POP3 connection string.
  • Visibility: public
  • Is abstract?: No
  • Is static?: No
  • Is final?: No
  • Returns: string

Parameters

Name Type Passed by reference? Variadic? Default Set Range Description
$host string No No required parameter N/A N/A The hostname
$port integer No No required parameter N/A N/A The port
$type ?string No No Null imap imaps imaps_nocert pop3 pop3s pop3s_nocert N/A The protocol (null: autodetect)

Returns

  • Connection string
  • Type: string
  • Set: N/A
  • Range: N/A

Preview

Code (PHP)

/**
 * Get an IMAP/POP3 connection string.
 *
 * @param  string $host The hostname
 * @param  integer $port The port
 * @param  ?string $type The protocol (null: autodetect)
 * @set imap imaps imaps_nocert pop3 pop3s pop3s_nocert
 * @return string Connection string
 */

function _imap_server_spec(string $host, int $port, ?string $type = null) : string