r100748 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r100747‎ | r100748 | r100749 >
Date:21:43, 25 October 2011
Author:kaldari
Status:ok
Tags:fundraising 
Comment:
more message migration
Modified paths:
  • /trunk/extensions/DonationInterface/gateway_forms/Form.php (modified) (history)
  • /trunk/extensions/DonationInterface/globalcollect_gateway/globalcollect_resultswitcher.body.php (modified) (history)
  • /trunk/extensions/DonationInterface/payflowpro_gateway/payflowpro_gateway.body.php (modified) (history)

Diff [purge]

Index: trunk/extensions/DonationInterface/payflowpro_gateway/payflowpro_gateway.body.php
@@ -148,11 +148,11 @@
149149 $countries = GatewayForm::getCountries();
150150
151151 $rows = array(
152 - 'title' => array( wfMsg( 'payflowpro_gateway-post-transaction' ) ),
153 - 'amount' => array( wfMsg( 'payflowpro_gateway-donor-amount' ), $data['amount'] ),
154 - 'email' => array( wfMsg( 'payflowpro_gateway-donor-email' ), $data['email'] ),
155 - 'name' => array( wfMsg( 'payflowpro_gateway-donor-name' ), $data['fname'], $data['mname'], $data['lname'] ),
156 - 'address' => array( wfMsg( 'payflowpro_gateway-donor-address' ), $data['street'], $data['city'], $data['state'], $data['zip'], $countries[$data['country']] ),
 152+ 'title' => array( wfMsg( 'donate_interface-post-transaction' ) ),
 153+ 'amount' => array( wfMsg( 'donate_interface-donor-amount' ), $data['amount'] ),
 154+ 'email' => array( wfMsg( 'donate_interface-donor-email' ), $data['email'] ),
 155+ 'name' => array( wfMsg( 'donate_interface-donor-name' ), $data['fname'], $data['mname'], $data['lname'] ),
 156+ 'address' => array( wfMsg( 'donate_interface-donor-address' ), $data['street'], $data['city'], $data['state'], $data['zip'], $countries[$data['country']] ),
157157 );
158158
159159 // if we want to show the response
@@ -194,7 +194,7 @@
195195 function fnPayflowDisplayPending( $responseMsg ) {
196196 global $wgOut;
197197
198 - $thankyou = wfMsg( 'payflowpro_gateway-thankyou' );
 198+ $thankyou = wfMsg( 'donate_interface-thankyou' );
199199
200200 // display response message
201201 $wgOut->addHTML( '<h2 class="response_message">' . $thankyou . '</h2>' );
Index: trunk/extensions/DonationInterface/gateway_forms/Form.php
@@ -126,9 +126,9 @@
127127 $form .= Xml::tags( 'p', array( 'class' => '' ), Xml::openElement( 'img', array( 'src' => $wgScriptPath . "/extensions/DonationInterface/gateway_forms/includes/rapidssl_ssl_certificate-nonanimated.png" ) ) );
128128 $form .= Xml::closeElement( 'div' ); // close div#payflowpro_gateway-donate-addl-info-secure-logos
129129 $form .= Xml::openElement( 'div', array( 'id' => 'payflowpro_gateway-donate-addl-info-text' ) );
130 - $form .= Xml::tags( 'p', array( 'class' => '' ), wfMsg( 'payflowpro_gateway-otherways-short' ) );
131 - $form .= Xml::tags( 'p', array( 'class' => '' ), wfMsg( 'payflowpro_gateway-credit-storage-processing' ) );
132 - $form .= Xml::tags( 'p', array( 'class' => '' ), wfMsg( 'payflowpro_gateway-question-comment' ) );
 130+ $form .= Xml::tags( 'p', array( 'class' => '' ), wfMsg( 'donate_interface-otherways-short' ) );
 131+ $form .= Xml::tags( 'p', array( 'class' => '' ), wfMsg( 'donate_interface-credit-storage-processing' ) );
 132+ $form .= Xml::tags( 'p', array( 'class' => '' ), wfMsg( 'donate_interface-question-comment' ) );
133133 $form .= Xml::closeElement( 'div' ); // close div#payflowpro_gateway-donate-addl-info-text
134134 $form .= Xml::closeElement( 'div' ); // close div#payflowpro_gateway-donate-addl-info
135135 return $form;
@@ -146,7 +146,7 @@
147147
148148 // create a new array of countries with potentially translated country names for alphabetizing later
149149 foreach ( GatewayForm::getCountries() as $iso_value => $full_name ) {
150 - $countries[$iso_value] = wfMsg( 'payflowpro_gateway-country-dropdown-' . $iso_value );
 150+ $countries[$iso_value] = wfMsg( 'donate_interface-country-dropdown-' . $iso_value );
151151 }
152152
153153 // alphabetically sort the country names
@@ -169,7 +169,7 @@
170170 'name' => 'country',
171171 'id' => 'country'
172172 ) );
173 - $country_menu .= Xml::option( wfMsg( 'payflowpro_gateway-select-country' ), '', false );
 173+ $country_menu .= Xml::option( wfMsg( 'donate_interface-select-country' ), '', false );
174174 $country_menu .= $country_options;
175175 $country_menu .= Xml::closeElement( 'select' );
176176
@@ -227,7 +227,7 @@
228228 for ( $i = 1; $i < 13; $i++ ) {
229229 $selected = ( $i == $month && $this->test ) ? true : false;
230230 $expiry_months .= Xml::option(
231 - wfMsg( 'payflowpro_gateway-month', $i, $wgLang->getMonthName( $i ) ),
 231+ wfMsg( 'donate_interface-month', $i, $wgLang->getMonthName( $i ) ),
232232 str_pad( $i, 2, '0', STR_PAD_LEFT ),
233233 $selected );
234234 }
@@ -286,7 +286,7 @@
287287 // generate dropdown of state opts
288288 foreach ( $states as $value => $state_name ) {
289289 $selected = ( $this->form_data['state'] == $value ) ? true : false;
290 - $state_opts .= Xml::option( wfMsg( 'payflowpro_gateway-state-dropdown-' . $value ), $value, $selected );
 290+ $state_opts .= Xml::option( wfMsg( 'donate_interface-state-dropdown-' . $value ), $value, $selected );
291291 }
292292
293293 $state_menu = Xml::openElement(
@@ -444,7 +444,7 @@
445445 $form .= '<td colspan=2><span class="creditcard-error-msg">' . $this->form_errors['emailAdd'] . '</span></td>';
446446 $form .= '</tr>';
447447 $form .= '<tr>';
448 - $form .= '<td class="label">' . Xml::label( wfMsg( 'payflowpro_gateway-donor-email' ), 'emailAdd' ) . '</td>';
 448+ $form .= '<td class="label">' . Xml::label( wfMsg( 'donate_interface-donor-email' ), 'emailAdd' ) . '</td>';
449449 $form .= '<td>' . Xml::input( 'emailAdd', '30', $this->form_data['email'], array( 'type' => 'text', 'maxlength' => '64', 'id' => 'emailAdd', 'class' => 'fullwidth' ) ) .
450450 '</td>';
451451 $form .= '</tr>';
@@ -462,7 +462,7 @@
463463 $form .= '<td colspan="2"><span class="creditcard-error-msg">' . $this->form_errors['invalidamount'] . '</span></td>';
464464 $form .= '</tr>';
465465 $form .= '<tr>';
466 - $form .= '<td class="label">' . Xml::label( wfMsg( 'payflowpro_gateway-donor-amount' ), 'amount' ) . '</td>';
 466+ $form .= '<td class="label">' . Xml::label( wfMsg( 'donate_interface-donor-amount' ), 'amount' ) . '</td>';
467467 $form .= '<td>' . Xml::radio( 'amount', 100, $this->form_data['amount'] == 100 ) . '100 ' .
468468 Xml::radio( 'amount', 50, $this->form_data['amount'] == 50 ) . '50 ' .
469469 Xml::radio( 'amount', 35, $this->form_data['amount'] == 35 ) . '35 ' .
@@ -471,7 +471,7 @@
472472 $form .= '</tr>';
473473 $form .= '<tr>';
474474 $form .= '<td class="label"></td>';
475 - $form .= '<td>' . Xml::radio( 'amount', $amount, $otherChecked, array( 'id' => 'otherRadio' ) ) . Xml::input( 'amountOther', '7', $this->form_data['amountOther'], array( 'type' => 'text', 'onfocus' => 'clearField( this, \'' . wfMsg( 'payflowpro_gateway-other' ) . '\' )', 'onblur' => 'document.getElementById("otherRadio").value = this.value;if (this.value > 0) document.getElementById("otherRadio").checked=true;', 'maxlength' => '10', 'id' => 'amountOther' ) ) .
 475+ $form .= '<td>' . Xml::radio( 'amount', $amount, $otherChecked, array( 'id' => 'otherRadio' ) ) . Xml::input( 'amountOther', '7', $this->form_data['amountOther'], array( 'type' => 'text', 'onfocus' => 'clearField( this, \'' . wfMsg( 'donate_interface-other' ) . '\' )', 'onblur' => 'document.getElementById("otherRadio").value = this.value;if (this.value > 0) document.getElementById("otherRadio").checked=true;', 'maxlength' => '10', 'id' => 'amountOther' ) ) .
476476 ' ' . $this->generateCurrencyDropdown() . '</td>';
477477 $form .= '</tr>';
478478 return $form;
@@ -491,7 +491,7 @@
492492 $form .= '</tr>';
493493 }
494494 $form .= '<tr>';
495 - $form .= '<td class="label">' . Xml::label( wfMsg( 'payflowpro_gateway-donor-card-num' ), 'card_num' ) . '</td>';
 495+ $form .= '<td class="label">' . Xml::label( wfMsg( 'donate_interface-donor-card-num' ), 'card_num' ) . '</td>';
496496 $form .= '<td>' . Xml::input( 'card_num', '30', $card_num, array( 'type' => 'text', 'maxlength' => '100', 'id' => 'card_num', 'class' => 'fullwidth', 'autocomplete' => 'off' ) ) .
497497 '</td>';
498498 $form .= '</tr>';
@@ -504,9 +504,9 @@
505505 $form = '<tr>';
506506 $form .= '<td colspan=2><span class="creditcard-error-msg">' . $this->form_errors['cvv'] . '</span></td>';
507507 $form .= '<tr>';
508 - $form .= '<td class="label">' . Xml::label( wfMsg( 'payflowpro_gateway-donor-security' ), 'cvv' ) . '</td>';
 508+ $form .= '<td class="label">' . Xml::label( wfMsg( 'donate_interface-donor-security' ), 'cvv' ) . '</td>';
509509 $form .= '<td>' . Xml::input( 'cvv', '5', $cvv, array( 'type' => 'text', 'maxlength' => '10', 'id' => 'cvv', 'autocomplete' => 'off' ) ) .
510 - ' ' . '<a href="javascript:PopupCVV();">' . wfMsg( 'payflowpro_gateway-cvv-link' ) . '</a>' .
 510+ ' ' . '<a href="javascript:PopupCVV();">' . wfMsg( 'donate_interface-cvv-link' ) . '</a>' .
511511 '</td>';
512512 $form .= '</tr>';
513513 return $form;
@@ -517,7 +517,7 @@
518518 $form .= '<td colspan=2><span class="creditcard-error-msg">' . $this->form_errors['street'] . '</span></td>';
519519 $form .= '</tr>';
520520 $form .= '<tr>';
521 - $form .= '<td class="label">' . Xml::label( wfMsg( 'payflowpro_gateway-donor-street' ), 'street' ) . '</td>';
 521+ $form .= '<td class="label">' . Xml::label( wfMsg( 'donate_interface-donor-street' ), 'street' ) . '</td>';
522522 $form .= '<td>' . Xml::input( 'street', '30', $this->form_data['street'], array( 'type' => 'text', 'maxlength' => '100', 'id' => 'street', 'class' => 'fullwidth' ) ) .
523523 '</td>';
524524 $form .= '</tr>';
@@ -529,7 +529,7 @@
530530 $form .= '<td colspan=2><span class="creditcard-error-msg">' . $this->form_errors['city'] . '</span></td>';
531531 $form .= '</tr>';
532532 $form .= '<tr>';
533 - $form .= '<td class="label">' . Xml::label( wfMsg( 'payflowpro_gateway-donor-city' ), 'city' ) . '</td>';
 533+ $form .= '<td class="label">' . Xml::label( wfMsg( 'donate_interface-donor-city' ), 'city' ) . '</td>';
534534 $form .= '<td>' . Xml::input( 'city', '30', $this->form_data['city'], array( 'type' => 'text', 'maxlength' => '40', 'id' => 'city', 'class' => 'fullwidth' ) ) .
535535 '</td>';
536536 $form .= '</tr>';
@@ -541,7 +541,7 @@
542542 $form .= '<td colspan=2><span class="creditcard-error-msg">' . $this->form_errors['zip'] . '</span></td>';
543543 $form .= '</tr>';
544544 $form .= '<tr>';
545 - $form .= '<td class="label">' . Xml::label( wfMsg( 'payflowpro_gateway-donor-postal' ), 'zip' ) . '</td>';
 545+ $form .= '<td class="label">' . Xml::label( wfMsg( 'donate_interface-donor-postal' ), 'zip' ) . '</td>';
546546 $form .= '<td>' . Xml::input( 'zip', '30', $this->form_data['zip'], array( 'type' => 'text', 'maxlength' => '9', 'id' => 'zip', 'class' => 'fullwidth' ) ) .
547547 '</td>';
548548 $form .= '</tr>';
@@ -556,9 +556,9 @@
557557 $form .= '<td colspan=2><span class="creditcard-error-msg">' . $this->form_errors['lname'] . '</span></td>';
558558 $form .= '</tr>';
559559 $form .= '<tr>';
560 - $form .= '<td class="label">' . Xml::label( wfMsg( 'payflowpro_gateway-donor-name' ), 'fname' ) . '</td>';
561 - $form .= '<td>' . Xml::input( 'fname', '30', $this->form_data['fname'], array( 'type' => 'text', 'onfocus' => 'clearField( this, \'' . wfMsg( 'payflowpro_gateway-donor-fname' ) . '\' )', 'maxlength' => '25', 'class' => 'required', 'id' => 'fname' ) ) .
562 - Xml::input( 'lname', '30', $this->form_data['lname'], array( 'type' => 'text', 'onfocus' => 'clearField( this, \'' . wfMsg( 'payflowpro_gateway-donor-lname' ) . '\' )', 'maxlength' => '25', 'id' => 'lname' ) ) . '</td>';
 560+ $form .= '<td class="label">' . Xml::label( wfMsg( 'donate_interface-donor-name' ), 'fname' ) . '</td>';
 561+ $form .= '<td>' . Xml::input( 'fname', '30', $this->form_data['fname'], array( 'type' => 'text', 'onfocus' => 'clearField( this, \'' . wfMsg( 'donate_interface-donor-fname' ) . '\' )', 'maxlength' => '25', 'class' => 'required', 'id' => 'fname' ) ) .
 562+ Xml::input( 'lname', '30', $this->form_data['lname'], array( 'type' => 'text', 'onfocus' => 'clearField( this, \'' . wfMsg( 'donate_interface-donor-lname' ) . '\' )', 'maxlength' => '25', 'id' => 'lname' ) ) . '</td>';
563563 $form .= "</tr>";
564564 return $form;
565565 }
@@ -574,7 +574,7 @@
575575
576576 protected function getCommentField() {
577577 $form = '<tr>';
578 - $form .= '<td class="label">' . Xml::label( wfMsg( 'payflowpro_gateway-comment' ), 'comment' ) . '</td>';
 578+ $form .= '<td class="label">' . Xml::label( wfMsg( 'donate_interface-comment' ), 'comment' ) . '</td>';
579579 $form .= '<td>' . Xml::input( 'comment', '30', $this->form_data['comment'], array( 'type' => 'text', 'maxlength' => '200', 'class' => 'fullwidth' ) ) . '</td>';
580580 $form .= '</tr>';
581581 return $form;
@@ -624,7 +624,7 @@
625625 $form .= '<td colspan=2><span class="creditcard-error-msg">' . $this->form_errors['state'] . '</span></td>';
626626 $form .= '</tr>';
627627 $form .= '<tr>';
628 - $form .= '<td class="label">' . Xml::label( wfMsg( 'payflowpro_gateway-donor-state' ), 'state' ) . '</td>';
 628+ $form .= '<td class="label">' . Xml::label( wfMsg( 'donate_interface-donor-state' ), 'state' ) . '</td>';
629629 $form .= '<td>' . $this->generateStateDropdown() . '</td>';
630630 $form .= '</tr>';
631631 return $form;
@@ -635,7 +635,7 @@
636636 $form .= '<td colspan=2><span class="creditcard-error-msg">' . $this->form_errors['country'] . '</span></td>';
637637 $form .= '</tr>';
638638 $form .= '<tr>';
639 - $form .= '<td class="label">' . Xml::label( wfMsg( 'payflowpro_gateway-donor-country' ), 'country' ) . '</td>';
 639+ $form .= '<td class="label">' . Xml::label( wfMsg( 'donate_interface-donor-country' ), 'country' ) . '</td>';
640640 $form .= '<td>' . $this->generateCountryDropdown( $defaultCountry ) . '</td>';
641641 $form .= '</tr>';
642642 return $form;
@@ -643,7 +643,7 @@
644644
645645 protected function getCreditCardTypeField() {
646646 $form = '<tr>';
647 - $form .= '<td class="label">' . Xml::label( wfMsg( 'payflowpro_gateway-donor-card' ), 'card_type' ) . '</td>';
 647+ $form .= '<td class="label">' . Xml::label( wfMsg( 'donate_interface-donor-card' ), 'card_type' ) . '</td>';
648648 $form .= '<td>' . $this->generateCardDropdown() . '</td>';
649649 $form .= '</tr>';
650650 return $form;
@@ -651,7 +651,7 @@
652652
653653 protected function getExpiryField() {
654654 $form = '<tr>';
655 - $form .= '<td class="label">' . Xml::label( wfMsg( 'payflowpro_gateway-donor-expiration' ), 'expiration' ) . '</td>';
 655+ $form .= '<td class="label">' . Xml::label( wfMsg( 'donate_interface-donor-expiration' ), 'expiration' ) . '</td>';
656656 $form .= '<td>' . $this->generateExpiryMonthDropdown() . $this->generateExpiryYearDropdown() . '</td>';
657657 $form .= '</tr>';
658658 return $form;
@@ -690,9 +690,9 @@
691691
692692 $form = '<noscript>';
693693 $form .= '<div id="noscript">';
694 - $form .= '<p id="noscript-msg">' . wfMsg( 'payflowpro_gateway-noscript-msg' ) . '</p>';
 694+ $form .= '<p id="noscript-msg">' . wfMsg( 'donate_interface-noscript-msg' ) . '</p>';
695695 if ( $noScriptRedirect ) {
696 - $form .= '<p id="noscript-redirect-msg">' . wfMsg( 'payflowpro_gateway-noscript-redirect-msg' ) . '</p>';
 696+ $form .= '<p id="noscript-redirect-msg">' . wfMsg( 'donate_interface-noscript-redirect-msg' ) . '</p>';
697697 $form .= '<p id="noscript-redirect-link"><a href="' . $noScriptRedirect . '">' . $noScriptRedirect . '</a></p>';
698698 }
699699 $form .= '</div>';
Index: trunk/extensions/DonationInterface/globalcollect_gateway/globalcollect_resultswitcher.body.php
@@ -93,7 +93,7 @@
9494 } else {
9595 if ( !$this->adapter->isCache() ) {
9696 // if we're not caching, there's a token mismatch
97 - $this->errors['general']['token-mismatch'] = wfMsg( 'payflowpro_gateway-token-mismatch' );
 97+ $this->errors['general']['token-mismatch'] = wfMsg( 'donate_interface-token-mismatch' );
9898 }
9999 }
100100 }

Status & tagging log