mirror of
https://github.com/wallabag/wallabag.git
synced 2025-08-01 17:38:38 +00:00
Add IPv4 url support (and others beginning by a digit)
This commit is contained in:
parent
7374ff30ef
commit
38b95e7be9
1 changed files with 1 additions and 3 deletions
|
@ -27,9 +27,7 @@ class Url
|
||||||
|
|
||||||
public function isCorrect()
|
public function isCorrect()
|
||||||
{
|
{
|
||||||
$pattern = '|^(.*:)//([a-z\-.\d]+)(:[0-9]+)?(.*)$|i';
|
return filter_var($this->url, FILTER_VALIDATE_URL);
|
||||||
|
|
||||||
return preg_match($pattern, $this->url);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public function clean()
|
public function clean()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue