Changeset 720

Show
Ignore:
Timestamp:
08/15/2007 10:39:21 AM (3 years ago)
Author:
JavaWoman
Message:

a little cleanup after changes for relocation.

refs #496

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/handlers/edit/edit.php

    r687 r720  
    132132                                        // now we render it internally so we can write the updated link table. 
    133133                                        // if we no longer do link tracking for header and footer why are we creating dummy output? 
    134                                         // @@@ test! 
    135134                                        $this->ClearLinkTable(); 
    136135                                        #$dummy = $this->Header();              // !!! 
     
    255254                if ($this->GetConfigValue('gui_editor') == 1)   // @@@ cast to boolean and compare to TRUE 
    256255                { 
    257                         // Relocation: replaced paths using configured value(s) 
    258                         #$output .= '<script type="text/javascript" src="'.$this->StaticHref('3rdparty/plugins/wikiedit/protoedit.js').'"></script>'."\n". 
    259                         #                  '<script type="text/javascript" src="'.$this->StaticHref('3rdparty/plugins/wikiedit/wikiedit2.js').'"></script>'."\n"; 
     256                        // Relocation: build paths using configured value(s) 
    260257                        $protoedit_url = $this->StaticHref($this->GetConfigValue('wikiedit_uripath').'/protoedit.js'); 
    261258                        $wikiedit_path = $this->StaticHref($this->GetConfigValue('wikiedit_uripath').'/wikiedit2.js'); 
    262259                        $output .= '<script type="text/javascript" src="'.$protoedit_url.'"></script>'."\n". 
    263260                                           '<script type="text/javascript" src="'.$wikiedit_path.'"></script>'."\n"; 
    264                         #$output .= '<script type="text/javascript">'."  wE = new WikiEdit(); wE.init('body','WikiEdit','editornamecss');".'</script>'."\n"; 
    265                         // Relocation: we need to pass image path (ending in '/') relative to configured path as a fourth parameter to wE.init : 
     261                        // Relocation: we need to pass image path (ending in '/') relative to 
     262                        // configured WikiEdit path as a fourth parameter to wE.init : 
    266263                        // that way WikiEdit can find its own images even if it's relocated/shared 
    267                         $wikiedit_imgpath = $this->StaticHref($this->GetConfigValue('wikiedit_uripath').'/images/');    // relative path breaks when not using base_url and with rewrite mode 
     264                        $wikiedit_imgpath = $this->StaticHref($this->GetConfigValue('wikiedit_uripath').'/images/'); 
    268265                        $output .= '<script type="text/javascript">'."  wE = new WikiEdit(); wE.init('body','WikiEdit','editornamecss','".$wikiedit_imgpath."');".'</script>'."\n"; 
    269266                }