diff options
author | Andrew Dolgov <[email protected]> | 2022-03-22 11:26:22 +0300 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2022-03-22 11:26:22 +0300 |
commit | 711662948768492e8d05b778a7d80eacaec368d2 (patch) | |
tree | 22fa067f16943e6de0e5b035a756dfd1fc5863ce | |
parent | 1703850215a282a31e9970e28ef8e7d930e4cc27 (diff) |
af_readability: ask readability-php library to fix relative URLs
-rwxr-xr-x | plugins/af_readability/init.php | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/plugins/af_readability/init.php b/plugins/af_readability/init.php index f9b49329f..7027db4a7 100755 --- a/plugins/af_readability/init.php +++ b/plugins/af_readability/init.php @@ -218,7 +218,11 @@ class Af_Readability extends Plugin { } try { - $r = new Readability(new Configuration()); + + $r = new Readability(new Configuration([ + 'fixRelativeURLs' => true, + 'originalURL' => $url, + ])); if ($r->parse($tmp)) { |