From 9fbc42294e7667c5ef19cafa0d1fcfbc1c0f36a9 Mon Sep 17 00:00:00 2001 From: ArthurHoaro Date: Sun, 26 Jul 2020 14:43:10 +0200 Subject: New basePath: fix officiel plugin paths and vintage template --- plugins/archiveorg/archiveorg.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'plugins/archiveorg/archiveorg.php') diff --git a/plugins/archiveorg/archiveorg.php b/plugins/archiveorg/archiveorg.php index 0ee1c73c..f26e6129 100644 --- a/plugins/archiveorg/archiveorg.php +++ b/plugins/archiveorg/archiveorg.php @@ -17,12 +17,13 @@ use Shaarli\Plugin\PluginManager; function hook_archiveorg_render_linklist($data) { $archive_html = file_get_contents(PluginManager::$PLUGINS_PATH . '/archiveorg/archiveorg.html'); + $path = ($data['_BASE_PATH_'] ?? '') . '/' . PluginManager::$PLUGINS_PATH; foreach ($data['links'] as &$value) { if ($value['private'] && preg_match('/^\?[a-zA-Z0-9-_@]{6}($|&|#)/', $value['real_url'])) { continue; } - $archive = sprintf($archive_html, $value['url'], t('View on archive.org')); + $archive = sprintf($archive_html, $value['url'], $path, t('View on archive.org')); $value['link_plugin'][] = $archive; } -- cgit v1.2.3