Index: trunk/extensions/MetavidWiki/includes/MV_GlobalFunctions.php |
— | — | @@ -291,8 +291,8 @@ |
292 | 292 | * enables linkback and autocomplete for search |
293 | 293 | */ |
294 | 294 | function mvfAutoAllPageHeader() { |
295 | | - global $mvgScriptPath, $wgJsMimeType, $wgOut, $mvExtraHeader, $wgTitle; |
296 | | - global $mvgJSDebug, $wgEnableScriptLoader, $wgRequest; |
| 295 | + global $mvgScriptPath, $wgJsMimeType, $wgOut, $mvExtraHeader; |
| 296 | + global $mvgJSDebug; |
297 | 297 | |
298 | 298 | $mvgScriptPath = htmlspecialchars( $mvgScriptPath ); |
299 | 299 | $wgJsMimeType = htmlspecialchars( $wgJsMimeType ) ; |
— | — | @@ -304,10 +304,6 @@ |
305 | 305 | $unique_req_param = MV_VERSION; |
306 | 306 | } |
307 | 307 | |
308 | | - $wgOut->addScriptClass( "mv_allpages" ); |
309 | | - $wgOut->addScriptClass( "mv_search" ); |
310 | | - |
311 | | - |
312 | 308 | $mvCssUrl = $mvgScriptPath . '/skins/mv_custom.css'; |
313 | 309 | $wgOut->addLink( array( |
314 | 310 | 'rel' => 'stylesheet', |
Index: trunk/extensions/MetavidWiki/includes/MV_Hooks.php |
— | — | @@ -133,14 +133,15 @@ |
134 | 134 | return true; |
135 | 135 | } |
136 | 136 | function mvAddToolBoxLinks(){ |
137 | | - global $wgTitle,$wgUser,$wgArticle; |
| 137 | + global $wgTitle,$wgUser; |
138 | 138 | if( $wgTitle->getNamespace() == MV_NS_STREAM){ |
139 | 139 | //make sure the Messages are loaded |
140 | 140 | //add export cmml link: |
141 | 141 | $sTitle = SpecialPage::getTitleFor( 'MvExportStream' ); |
| 142 | + $mvTitle = new MV_Title( $wgTitle->getDBkey() ); |
142 | 143 | $sk = $wgUser->getSkin(); |
143 | 144 | $link = $sk->makeKnownLinkObj( $sTitle,wfMsg('mv_stream_resource_export'), |
144 | | - 'feed_format=roe&stream_name=' . htmlspecialchars( $wgArticle->mvTitle->getStreamName() ) . '&t=' . htmlspecialchars($wgArticle->mvTitle->getTimeRequest() ), |
| 145 | + 'feed_format=roe&stream_name=' . htmlspecialchars( $mvTitle->getStreamName() ) . '&t=' . htmlspecialchars( $mvTitle->getTimeRequest() ), |
145 | 146 | '', '', 'title="' . htmlspecialchars( wfMsg( 'mv_export_cmml' ) ) . '"' ); |
146 | 147 | echo "<li>" . $link . "</li>"; |
147 | 148 | } |
— | — | @@ -230,8 +231,8 @@ |
231 | 232 | if( !$wgRequest->getVal( 'UseExternalEditor' ) || $action=='submit' || $internal || |
232 | 233 | $section || $oldid || ( !$user->getOption( 'externaleditor' ) && !$external ) ) { |
233 | 234 | $editor = new MvEditSequence( $article ); |
234 | | - $editor->submit(); |
235 | | - } elseif( $wgRequest->getVal( 'UseExternalEditor' ) && ( $external || $user->getOption( 'externaleditor' ) ) ) { |
| 235 | + $editor->edit(); |
| 236 | + } else { |
236 | 237 | $mode = $wgRequest->getVal( 'mode' ); |
237 | 238 | $extedit = new ExternalEdit( $article, $mode ); |
238 | 239 | $extedit->edit(); |