summaryrefslogtreecommitdiff
path: root/inc/parser
diff options
context:
space:
mode:
authorKate Arzamastseva <pshns@ukr.net>2011-09-02 14:52:25 +0300
committerKate Arzamastseva <pshns@ukr.net>2011-09-02 14:52:25 +0300
commit4a24b45986919be03b551e34be6931eb88a37ec0 (patch)
tree2525d0417ae4866a2b6f34016baea3589b4abd18 /inc/parser
parent30fd72fbc3c8bd3fbcae4f7041aa0e001a719c6a (diff)
downloadrpg-4a24b45986919be03b551e34be6931eb88a37ec0.tar.gz
rpg-4a24b45986919be03b551e34be6931eb88a37ec0.tar.bz2
issue #46 Render links to missing media files as link to the media manager
Diffstat (limited to 'inc/parser')
-rw-r--r--inc/parser/xhtml.php6
1 files changed, 4 insertions, 2 deletions
diff --git a/inc/parser/xhtml.php b/inc/parser/xhtml.php
index 83359cd55..ea1756803 100644
--- a/inc/parser/xhtml.php
+++ b/inc/parser/xhtml.php
@@ -805,8 +805,10 @@ class Doku_Renderer_xhtml extends Doku_Renderer {
if($hash) $link['url'] .= '#'.$hash;
//markup non existing files
- if (!$exists)
- $link['class'] .= ' wikilink2';
+ if (!$exists) {
+ $link['class'] .= ' wikilink2';
+ $link['url'] = media_managerURL(array('tab_details' => 'view', 'image' => $src, 'ns' => getNS($src)), '&');
+ }
//output formatted
if ($linking == 'nolink' || $noLink) $this->doc .= $link['name'];