r65648 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r65647‎ | r65648 | r65649 >
Date:23:37, 28 April 2010
Author:jeroendedauw
Status:deferred
Tags:
Comment:
Fixed style for validation errors
Modified paths:
  • /trunk/extensions/Storyboard/specials/StorySubmission/StorySubmission_body.php (modified) (history)
  • /trunk/extensions/Storyboard/storyboard.css (modified) (history)
  • /trunk/extensions/Storyboard/tags/Storysubmission/Storysubmission_body.php (modified) (history)

Diff [purge]

Index: trunk/extensions/Storyboard/storyboard.css
@@ -64,11 +64,15 @@
6565 float: right;
6666 }
6767
 68+.validationerror {
 69+ color: red;
 70+}
 71+
6872 /**
6973 * Css for <storyboard> tags
7074 */
7175 .storyboard {
72 -border: 1px solid #ddd;
 76+ border: 1px solid #ddd;
7377 }
7478 .storyboard .storyboard-batch {
7579 margin: 0;
Index: trunk/extensions/Storyboard/tags/Storysubmission/Storysubmission_body.php
@@ -27,8 +27,6 @@
2828 * @param $frame
2929 *
3030 * @return array
31 - *
32 - * FIXME: the submission broke somehow
3331 */
3432 public static function render( $input, array $args, Parser $parser, $frame ) {
3533 wfProfileIn( __METHOD__ );
@@ -213,15 +211,13 @@
214212
215213 $formBody .= Html::hidden( 'lang', $args['language'] );
216214
217 - $submissionUrl = SpecialPage::getTitleFor( 'StorySubmission' )->getFullURL();
218 -
219215 return Html::rawElement(
220216 'form',
221217 array(
222218 'id' => 'storyform',
223219 'name' => 'storyform',
224220 'method' => 'post',
225 - 'action' => $submissionUrl,
 221+ 'action' => SpecialPage::getTitleFor( 'StorySubmission' )->getFullURL(),
226222 'onsubmit' => 'return stbValidateSubmission( "storyboard-agreement" );'
227223 ),
228224 $formBody
Index: trunk/extensions/Storyboard/specials/StorySubmission/StorySubmission_body.php
@@ -83,7 +83,11 @@
8484 $wgOut->setPageTitle( wfMsg( 'storyboard-submissionincomplete' ) );
8585
8686 $wgOut->addWikiMsg( 'storyboard-alreadyexists', $title, $wgTitle->getFullURL() );
87 - $wgOut->addHtml( '<a href="#" onclick="history.go(-1); return false;">' . wfMsg( 'storyboard-changetitle' ) . '</a>' );
 87+
 88+ // Let's not give a null link to people with no JS.
 89+ // TODO: change this to the last page somehow
 90+ $fallBackUrl = Title::newMainPage()->getFullURL();
 91+ $wgOut->addHtml( "<a href='$fallBackUrl' onclick='history.go(-1); return false;'>" . wfMsg( 'storyboard-changetitle' ) . '</a>' );
8892 }
8993 }
9094

Status & tagging log