|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2010-03-03 08:49 UTC] solar at azrael dot ws
Description: ------------ Hostname must contain only alpha-numeric letters and the hyphen(-). Test script: --------------- var_dump(filter_var( Expected result: ---------------- string(18) "http://example.com" string(19) "http://exa-mple.com" bool(false) Actual result: -------------- string(18) "http://example.com" bool(false) string(19) "http://exa_mple.com" PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Nov 09 04:00:01 2025 UTC |
Oops. Test script: var_dump(filter_var('http://example.com', FILTER_VALIDATE_URL)); var_dump(filter_var('http://exa-mple.com', FILTER_VALIDATE_URL)); var_dump(filter_var('http://exa_mple.com', FILTER_VALIDATE_URL));