mirror of
https://github.com/moparisthebest/wallabag
synced 2024-11-27 11:22:17 -05:00
Merge pull request #174 from nicofrand/dev
Add support for URLS with digits
This commit is contained in:
commit
83954e711d
@ -27,9 +27,7 @@ class Url
|
|||||||
|
|
||||||
public function isCorrect()
|
public function isCorrect()
|
||||||
{
|
{
|
||||||
$pattern = '|^(.*:)//([a-z\-.]+)(:[0-9]+)?(.*)$|i';
|
return filter_var($this->url, FILTER_VALIDATE_URL) !== FALSE;
|
||||||
|
|
||||||
return preg_match($pattern, $this->url);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public function clean()
|
public function clean()
|
||||||
@ -73,7 +71,7 @@ class Url
|
|||||||
if (preg_replace('/\s+/', '', $body->value) !== "<body></body>") {
|
if (preg_replace('/\s+/', '', $body->value) !== "<body></body>") {
|
||||||
$html = $tidy->value;
|
$html = $tidy->value;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$parameters = array();
|
$parameters = array();
|
||||||
if (isset($html) and strlen($html) > 0)
|
if (isset($html) and strlen($html) > 0)
|
||||||
|
Loading…
Reference in New Issue
Block a user