From: Jan Schneider Date: Fri, 15 Oct 2010 12:07:33 +0000 (+0200) Subject: Use global mod_rewrite configuration. X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=b41e222abd180cbf8cb4cf85bb512c8cffac48d3;p=horde.git Use global mod_rewrite configuration. --- diff --git a/wicked/config/conf.xml b/wicked/config/conf.xml index f9747cd79..51860b30f 100644 --- a/wicked/config/conf.xml +++ b/wicked/config/conf.xml @@ -47,11 +47,6 @@ - - Look and feel - false - - Menu Settings diff --git a/wicked/lib/Text_Wiki/Render/Xhtml/Wikilink2.php b/wicked/lib/Text_Wiki/Render/Xhtml/Wikilink2.php index 1eaa71ad8..4a2ad7d93 100644 --- a/wicked/lib/Text_Wiki/Render/Xhtml/Wikilink2.php +++ b/wicked/lib/Text_Wiki/Render/Xhtml/Wikilink2.php @@ -47,14 +47,11 @@ class Text_Wiki_Render_Xhtml_Wikilink2 extends Text_Wiki_Render_Xhtml_Wikilink { } } - $anchor = '#'.$this->urlEncode(substr($anchor, 1)); + $anchor = '#' . $this->urlEncode(substr($anchor, 1)); - // does the page exist? + // Does the page exist? if ($exists) { - - // PAGE EXISTS. - - $href = sprintf($this->getConf('view_url'), (!empty($GLOBALS['conf']['options']['use_mod_rewrite']) ? htmlspecialchars($page) : $this->urlEncode($page))) . $anchor; + $href = sprintf($this->getConf('view_url'), $GLOBALS['conf']['urls']['pretty'] == 'rewrite' ? htmlspecialchars($page) : $this->urlEncode($page)) . $anchor; // get the CSS class and generate output $css = ' class="'.$this->textEncode($this->getConf('css')).'"'; @@ -62,9 +59,6 @@ class Text_Wiki_Render_Xhtml_Wikilink2 extends Text_Wiki_Render_Xhtml_Wikilink { $start = ''; $end = ''; } else { - - // PAGE DOES NOT EXIST. - $new_url = $this->getConf('new_url'); if (!$new_url) { return $this->textEncode($text); diff --git a/wicked/lib/Wicked.php b/wicked/lib/Wicked.php index 2c33d5025..afea0fe8f 100644 --- a/wicked/lib/Wicked.php +++ b/wicked/lib/Wicked.php @@ -75,9 +75,7 @@ class Wicked */ public static function url($page, $full = false, $append_session = 0) { - global $conf; - - if (!empty($conf['options']['use_mod_rewrite'])) { + if ($GLOBALS['conf']['urls']['pretty'] == 'rewrite') { $script = str_replace('%2F', '/', urlencode($page)); } else { $script = Horde_Util::addParameter('display.php', 'page', $page);