note 91066 added to function.parse-url
| From: | Anonymous at osu1 dot php dot net | Date: | Sat, 23 May 2009 09:41:09 +0000 |
| Subject: | note 91066 added to function.parse-url | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-155905@lists.php.net to get a copy of this message | ||
As a reply to theoriginalmarksimpson at gmail dot com
It is even easier to check for a valid url like this:
<?php
$ftp = parse_url("ftp://253.124.125.547");
if(!isset($ftp['ip']) || ip2long($ftp['ip']) === FALSE)
{
echo "false!";
}
?>
----
Server IP: 83.137.20.135
Probable Submitter: 84.26.112.229
----
Manual Page -- http://www.php.net/manual/en/function.parse-url.php
Edit -- https://master.php.net/note/edit/91066
Del: integrated -- https://master.php.net/note/delete/91066/integrated
Del: useless -- https://master.php.net/note/delete/91066/useless
Del: bad code -- https://master.php.net/note/delete/91066/bad+code
Del: spam -- https://master.php.net/note/delete/91066/spam
Del: non-english -- https://master.php.net/note/delete/91066/non-english
Del: in docs -- https://master.php.net/note/delete/91066/in+docs
Del: other reasons-- https://master.php.net/note/delete/91066
Reject -- https://master.php.net/note/reject/91066
Search -- https://master.php.net/manage/user-notes.php