af_redditimgur: better handling of image urls with multiple-character numeric suffixes
This commit is contained in:
parent
611e5ba37d
commit
5f58daa2fb
|
@ -84,9 +84,8 @@ class Af_RedditImgur extends Plugin {
|
||||||
$found = true;
|
$found = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (preg_match("/\.(jpg|jpeg|gif|png)(\?[0-9])?$/i", $entry->getAttribute("href"))) {
|
if (preg_match("/\.(jpg|jpeg|gif|png)(\?[0-9][0-9]*)?$/i", $entry->getAttribute("href"))) {
|
||||||
|
$img = $doc->createElement('img');
|
||||||
$img = $doc->createElement('img');
|
|
||||||
$img->setAttribute("src", $entry->getAttribute("href"));
|
$img->setAttribute("src", $entry->getAttribute("href"));
|
||||||
|
|
||||||
$br = $doc->createElement('br');
|
$br = $doc->createElement('br');
|
||||||
|
|
Loading…
Reference in New Issue