SilverStripe\EnvironmentCheck\Checks\ExternalURLCheck
Checks that one or more URLs are reachable via HTTP.
Note that the HTTP connectivity can just be verified from the server to the remote URL,
it can still fail if the URL in question is requested by the client, e.g. through an iframe.
Requires curl to present, so ensure to check it before with the following:
<code>
EnvironmentCheckSuite::register(
'check',
'HasFunctionCheck("curl_init")',
"Does PHP have CURL support?"
);
</code>
Synopsis
class ExternalURLCheck
implements
EnvironmentCheck
{
- // methods
- public void __construct()
- public array check()
- protected array getCurlOpts()
- protected array getURLs()
Hierarchy
Constants
Name | Value |
---|---|
ERROR | 3 |
WARNING | 2 |
OK | 1 |
Members
protected
- $timeout — SilverStripe\EnvironmentCheck\Checks\Int
- $urls — array