Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
project
drupal
Commits
e8ee0bcd
Commit
e8ee0bcd
authored
Oct 09, 2006
by
Dries
Browse files
- Patch
#40209
by pascal and jvandyk: added missing semicolon to URL validation.
parent
8a478d50
Changes
1
Hide whitespace changes
Inline
Side-by-side
includes/common.inc
View file @
e8ee0bcd
...
...
@@ -689,7 +689,7 @@ function valid_email_address($mail) {
* TRUE if the URL is in a valid format.
*/
function
valid_url
(
$url
,
$absolute
=
FALSE
)
{
$allowed_characters
=
'[a-z0-9\/:_\-_\.\?\$,~=#&%\+]'
;
$allowed_characters
=
'[a-z0-9\/:_\-_\.\?\$,
;
~=#&%\+]'
;
if
(
$absolute
)
{
return
preg_match
(
"/^(http|https|ftp):\/\/"
.
$allowed_characters
.
"+$/i"
,
$url
);
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment