# HG changeset patch
# User Dan
# Date 1184183778 14400
# Node ID f6454d5fec7a3ea6fb93927a24d38b8e73e847fd
# Parent 52017732bc2030c093e678a1edb48fb0a9bc2fc8
Made raw images + internal/external links work right
diff -r 52017732bc20 -r f6454d5fec7a includes/render.php
--- a/includes/render.php Wed Jul 11 15:36:01 2007 -0400
+++ b/includes/render.php Wed Jul 11 15:56:18 2007 -0400
@@ -858,7 +858,12 @@
}
else if ( $caption == '|raw' )
{
- $complete_tag .= $img_tag;
+ $complete_tag .= "$img_tag";
+ $taglist[$i] = $complete_tag;
+
+ $repl = "{$s_delim}e_img_{$i}{$f_delim}";
+ $text = str_replace($full_tag, $repl, $text);
+ continue;
}
else
{
diff -r 52017732bc20 -r f6454d5fec7a includes/wikiengine/Render/Xhtml/Url.php
--- a/includes/wikiengine/Render/Xhtml/Url.php Wed Jul 11 15:36:01 2007 -0400
+++ b/includes/wikiengine/Render/Xhtml/Url.php Wed Jul 11 15:56:18 2007 -0400
@@ -100,9 +100,15 @@
}
// generate a regular link (not an image)
- $text = $this->textEncode($text);
+ // $text = $this->textEncode($text);
$css = $this->formatConf(' class="%s"', "css_$type");
$output = "/is', $text) )
+ {
+ $output .= ' style="background-image: none; padding-right: 0;"';
+ }
if ($target) {
// use a "popup" window. this is XHTML compliant, suggested by
diff -r 52017732bc20 -r f6454d5fec7a includes/wikiengine/Render/Xhtml/Wikilink.php
--- a/includes/wikiengine/Render/Xhtml/Wikilink.php Wed Jul 11 15:36:01 2007 -0400
+++ b/includes/wikiengine/Render/Xhtml/Wikilink.php Wed Jul 11 15:56:18 2007 -0400
@@ -99,7 +99,17 @@
// up what the user typed and what we're checking.
//$page = $this->urlEncode($page);
$anchor = $this->urlEncode($anchor);
- $text = $this->textEncode($text);
+ // $text = $this->textEncode($text);
+
+ // hackish fix for the "external" image in Oxygen [added for Enano]
+ if ( preg_match('/<(.+?)>/is', $text) )
+ {
+ $nobg = ' style="background-image: none; padding-right: 0;"';
+ }
+ else
+ {
+ $nobg = '';
+ }
// does the page exist?
if ($exists) {
@@ -123,7 +133,7 @@
// get the CSS class and generate output
$css = $this->formatConf(' class="%s"', 'css');
- $start = '';
+ $start = '';
$end = '';
} else {
@@ -146,7 +156,7 @@
// get the CSS class and generate output
$css = $this->formatConf(' class="%s"', 'css');
- $start = '';
+ $start = '';
$end = '';
}