Index: trunk/extensions/FCKeditor/FCKeditor.body.php |
— | — | @@ -145,19 +145,19 @@ |
146 | 146 | } |
147 | 147 | |
148 | 148 | public function onCustomEditor( $article, $user ) { |
149 | | - global $wgRequest, $mediaWiki; |
| 149 | + global $wgRequest, $wgUseExternalEditor; |
150 | 150 | |
151 | | - $action = $mediaWiki->getVal( 'Action' ); |
| 151 | + $action = $wgRequest->getVal( 'action', 'view' ); |
152 | 152 | |
153 | 153 | $internal = $wgRequest->getVal( 'internaledit' ); |
154 | 154 | $external = $wgRequest->getVal( 'externaledit' ); |
155 | 155 | $section = $wgRequest->getVal( 'section' ); |
156 | 156 | $oldid = $wgRequest->getVal( 'oldid' ); |
157 | | - if( !$mediaWiki->getVal( 'UseExternalEditor' ) || $action == 'submit' || $internal || |
| 157 | + if( !$wgUseExternalEditor || $action == 'submit' || $internal || |
158 | 158 | $section || $oldid || ( !$user->getOption( 'externaleditor' ) && !$external ) ) { |
159 | 159 | $editor = new FCKeditorEditPage( $article ); |
160 | 160 | $editor->submit(); |
161 | | - } elseif( $mediaWiki->getVal( 'UseExternalEditor' ) && ( $external || $user->getOption( 'externaleditor' ) ) ) { |
| 161 | + } elseif( $wgUseExternalEditor && ( $external || $user->getOption( 'externaleditor' ) ) ) { |
162 | 162 | $mode = $wgRequest->getVal( 'mode' ); |
163 | 163 | $extedit = new ExternalEdit( $article, $mode ); |
164 | 164 | $extedit->edit(); |