From fd7786f838496cb89abd4d0d145a4f0cac466515 Mon Sep 17 00:00:00 2001 From: Pablo Martin Date: Mon, 5 Nov 2012 08:04:51 +0000 Subject: dont include png files as php. --- views/default/dokuwiki/index.php | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'views/default') diff --git a/views/default/dokuwiki/index.php b/views/default/dokuwiki/index.php index e1c1120f8..424f1109b 100644 --- a/views/default/dokuwiki/index.php +++ b/views/default/dokuwiki/index.php @@ -1,6 +1,13 @@ pluginspath.'dokuwiki/vendors/dokuwiki/'.$vars['page']; - if (file_exists($destfile)) - include($destfile); + if (file_exists($destfile)) { + if (strpos($destfile, ".png") === FALSE) + { + include($destfile); + } else { + header("Content-type: image"); + echo file_get_contents($destfile); + } + } ?> -- cgit v1.2.3