REDROOM
PHP 8.2.30
Path:
Logout
Edit File
Size: 755 B
Close
/proc/thread-self/root/opt/cloudlinux/alt-php56/root/usr/share/pear/test/Mail/tests/smtp_error.phpt
Text
Base64
--TEST-- Mail: SMTP Error Reporting --SKIPIF-- <?php require_once 'PEAR/Registry.php'; $registry = new PEAR_Registry(); if (!$registry->packageExists('Net_SMTP')) die("skip\n"); --FILE-- <?php require_once 'Mail.php'; /* Reference a bogus SMTP server address to guarantee a connection failure. */ $params = array('host' => 'bogus.host.tld'); /* Create our SMTP-based mailer object. */ $mailer = Mail::factory('smtp', $params); /* Attempt to send an empty message in order to trigger an error. */ $e = $mailer->send(array(), array(), ''); if (is_a($e, 'PEAR_Error')) { $err = $e->getMessage(); if (preg_match('/Failed to connect to bogus.host.tld:25 \[SMTP: Failed to connect socket:.*/i', $err)) { echo "OK"; } } --EXPECT-- OK
Save
Close
Exit & Reset
Text mode: syntax highlighting auto-detects file type.
Directory Contents
Dirs: 0 × Files: 7
Delete Selected
Select All
Select None
Sort:
Name
Size
Modified
Enable drag-to-move
Name
Size
Perms
Modified
Actions
9137.phpt
1001 B
lrw-r--r--
2021-12-02 08:19:47
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
9137_2.phpt
1.20 KB
lrw-r--r--
2021-12-02 08:19:47
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
13659.phpt
649 B
lrw-r--r--
2021-12-02 08:19:47
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
bug17178.phpt
228 B
lrw-r--r--
2021-12-02 08:19:47
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
bug17317.phpt
421 B
lrw-r--r--
2021-12-02 08:19:47
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
rfc822.phpt
2.78 KB
lrw-r--r--
2021-12-02 08:19:47
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
smtp_error.phpt
755 B
lrw-r--r--
2021-12-02 08:19:47
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Zip Selected
If ZipArchive is unavailable, a
.tar
will be created (no compression).