Merge "PLURAL support for list lengths in default-skin-not-found"
[lhc/web/wiklou.git] / includes / EditPage.php
index a5994e7..e113426 100644 (file)
@@ -2670,19 +2670,21 @@ class EditPage {
                                                array( 'userinvalidcssjstitle', $this->mTitle->getSkinFromCssJsSubpage() )
                                        );
                                }
-                               if ( $this->formtype !== 'preview' ) {
-                                       if ( $this->isCssSubpage && $wgAllowUserCss ) {
-                                               $wgOut->wrapWikiMsg(
-                                                       "<div id='mw-usercssyoucanpreview'>\n$1\n</div>",
-                                                       array( 'usercssyoucanpreview' )
-                                               );
-                                       }
+                               if ( $this->getTitle()->isSubpageOf( $wgUser->getUserPage() ) ) {
+                                       if ( $this->formtype !== 'preview' ) {
+                                               if ( $this->isCssSubpage && $wgAllowUserCss ) {
+                                                       $wgOut->wrapWikiMsg(
+                                                               "<div id='mw-usercssyoucanpreview'>\n$1\n</div>",
+                                                               array( 'usercssyoucanpreview' )
+                                                       );
+                                               }
 
-                                       if ( $this->isJsSubpage && $wgAllowUserJs ) {
-                                               $wgOut->wrapWikiMsg(
-                                                       "<div id='mw-userjsyoucanpreview'>\n$1\n</div>",
-                                                       array( 'userjsyoucanpreview' )
-                                               );
+                                               if ( $this->isJsSubpage && $wgAllowUserJs ) {
+                                                       $wgOut->wrapWikiMsg(
+                                                               "<div id='mw-userjsyoucanpreview'>\n$1\n</div>",
+                                                               array( 'userjsyoucanpreview' )
+                                                       );
+                                               }
                                        }
                                }
                        }