[Since original poster requests for procedure for feature/change request.]

You can use bug reporting system to request new feature or changes.
http://www.php.net/bugs.php

Use "Feature/Change Request" as "Type of bug".
It will be sent to php-dev mail list and stored as feature/change request in db.

Regards,

--
Yasuo Ohgaki

"Mike" <[EMAIL PROTECTED]> wrote in message 1103_985083470@matthew">news:1103_985083470@matthew...
> On 19 Mar 2001 06:53:00 -0800, [EMAIL PROTECTED] ("David G.") wrote:
> > Since fopen/fread/fclose all work with standard URLs, why not allow
> > file_exists() to work with URLs as well?
> > What is the procedure to make such a request?
>
>
> Try this:
>
> function url_exist($url) {
> $url_parts = parse_url($url);
> $fp = fsockopen($url_parts["host"], 80);
> if (!$fp) return false;
> $path = $url_parts["path")?$url_parts["path"]:"/";
> fwrite($fp, "GET $path HTTP/1.0\r\n\r\n");
> $response = fgets($fp, 500);
> preg_match("/^HTTP\/\d\.\d[ \t]+(\d+)[ \t]*([^\r]*)/", $response, $matches);
> switch ($matches[1]) {
> case 404: // HTTP error not found
> return false;
> case 200: // HTTP OK
> return true;
> default:
> return false; // other responses probably counts false
> }
> }
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to