Index: trunk/extensions/ExtensionDistributor/ExtensionDistributor_body.php |
— | — | @@ -69,7 +69,7 @@ |
70 | 70 | |
71 | 71 | $this->extensionList = array(); |
72 | 72 | |
73 | | - foreach ( $wgExtDistBranches as $branchPath ) { |
| 73 | + foreach ( $wgExtDistBranches as $branchPath => $branch ) { |
74 | 74 | $wc = "$wgExtDistWorkingCopy/$branchPath/extensions"; |
75 | 75 | $dir = opendir( $wc ); |
76 | 76 | |
Index: trunk/extensions/FixedImage/FixedImage.php |
— | — | @@ -47,7 +47,7 @@ |
48 | 48 | |
49 | 49 | function fixedImageSetup( &$parser ) { |
50 | 50 | global $wgFixedImageHooks; |
51 | | - foreach( $wgFixedImageHooks as $key ) { |
| 51 | + foreach( $wgFixedImageHooks as $key => $data ) { |
52 | 52 | $wrapper = create_function( '$text, $params=null', |
53 | 53 | "return fixedImageHandler('$key', \$text, \$params);" ); |
54 | 54 | $parser->setHook( $key, $wrapper ); |
Index: trunk/extensions/SiteMatrix/SiteMatrix_body.php |
— | — | @@ -78,7 +78,7 @@ |
79 | 79 | uasort( $this->specials, array( __CLASS__, 'sortSpecial' ) ); |
80 | 80 | |
81 | 81 | if( $hideEmpty ){ |
82 | | - foreach( $xLanglist as $lang ){ |
| 82 | + foreach( $xLanglist as $lang => $unused ){ |
83 | 83 | $empty = true; |
84 | 84 | foreach ( $this->sites as $site ) { |
85 | 85 | if( !empty( $this->matrix[$site][$lang] ) ){ |
Index: trunk/extensions/ReaderFeedback/ReaderFeedback.hooks.php |
— | — | @@ -133,7 +133,7 @@ |
134 | 134 | 'onchange' => "updateFeedbackForm()" ); |
135 | 135 | $form .= ' ' . Xml::openElement( 'select', $attribs ); |
136 | 136 | $levels = array_reverse($levels,true); |
137 | | - foreach( $levels as $i ) { |
| 137 | + foreach( $levels as $i => $name ) { |
138 | 138 | $optionClass = array( 'class' => "rfb-rating-option-$i" ); |
139 | 139 | $form .= Xml::option( wfMsg("readerfeedback-level-$i"), $i, ($i == $selected), $optionClass ) ."\n"; |
140 | 140 | } |
Index: trunk/extensions/ReaderFeedback/specialpages/RatingHistory_body.php |
— | — | @@ -117,7 +117,7 @@ |
118 | 118 | $data = false; |
119 | 119 | $html = ''; |
120 | 120 | // Do each graphs for said time period |
121 | | - foreach( ReaderFeedback::getFeedbackTags() as $tag ) { |
| 121 | + foreach( ReaderFeedback::getFeedbackTags() as $tag => $weight ) { |
122 | 122 | // Check if cached version is available. |
123 | 123 | // If not, then generate a new one. |
124 | 124 | $filePath = $this->getFilePath( $tag ); |
Index: trunk/extensions/ReaderFeedback/specialpages/ReaderFeedback_body.php |
— | — | @@ -54,7 +54,7 @@ |
55 | 55 | # Get our rating dimensions |
56 | 56 | $this->dims = array(); |
57 | 57 | $unsureCount = 0; |
58 | | - foreach( ReaderFeedback::getFeedbackTags() as $tag ) { |
| 58 | + foreach( ReaderFeedback::getFeedbackTags() as $tag => $weight ) { |
59 | 59 | $this->dims[$tag] = $wgRequest->getIntOrNull( "wp$tag" ); |
60 | 60 | if( $this->dims[$tag] === null ) { // nothing sent at all :( |
61 | 61 | $wgOut->redirect( $this->page->getLocalUrl() ); |
Index: trunk/extensions/ReaderFeedback/ReaderFeedback.class.php |
— | — | @@ -204,7 +204,7 @@ |
205 | 205 | array( 'USE INDEX' => array('revision' => 'page_timestamp') ) |
206 | 206 | ); |
207 | 207 | $votes = array(); |
208 | | - foreach( ReaderFeedback::getFeedbackTags() as $tag ) { |
| 208 | + foreach( ReaderFeedback::getFeedbackTags() as $tag => $w ) { |
209 | 209 | $votes[$tag] = array( 0 => 0, 1 => 0, 2 => 0, 3 => 0, 4 => 0 ); |
210 | 210 | } |
211 | 211 | // Read votes and tally the numbers |
— | — | @@ -226,7 +226,7 @@ |
227 | 227 | } |
228 | 228 | // Output multi-column list |
229 | 229 | $html = "<table class='rfb-reader_feedback_table' cellspacing='0'><tr>"; |
230 | | - foreach( ReaderFeedback::getFeedbackTags() as $tag ) { |
| 230 | + foreach( ReaderFeedback::getFeedbackTags() as $tag => $w ) { |
231 | 231 | // Get tag average... |
232 | 232 | $dist = isset($votes[$tag]) ? $votes[$tag] : array(); |
233 | 233 | $count = array_sum($dist); |
Index: trunk/extensions/ReaderFeedback/ReaderFeedbackXML.php |
— | — | @@ -47,7 +47,7 @@ |
48 | 48 | public static function getTagMenu( $selected = '' ) { |
49 | 49 | $s = "<label for='wpRatingTag'>" . wfMsgHtml('readerfeedback-tagfilter') . "</label> "; |
50 | 50 | $s .= Xml::openElement( 'select', array('name' => 'ratingtag', 'id' => 'wpRatingTag') ); |
51 | | - foreach( ReaderFeedback::getFeedbackTags() as $tag ) { |
| 51 | + foreach( ReaderFeedback::getFeedbackTags() as $tag => $weight ) { |
52 | 52 | $s .= Xml::option( wfMsg( "readerfeedback-$tag" ), $tag, $selected===$tag ); |
53 | 53 | } |
54 | 54 | $s .= Xml::closeElement('select')."\n"; |
Index: trunk/extensions/SecurePoll/includes/talliers/SchulzeTallier.php |
— | — | @@ -93,7 +93,7 @@ |
94 | 94 | } |
95 | 95 | |
96 | 96 | # Now $winners is the list of candidates that tie for this position |
97 | | - foreach ( $winners as $oid ) { |
| 97 | + foreach ( $winners as $oid => $unused ) { |
98 | 98 | $ranks[$oid] = $currentRank; |
99 | 99 | } |
100 | 100 | $currentRank += count( $winners ); |
Index: trunk/extensions/SecurePoll/includes/talliers/PluralityTallier.php |
— | — | @@ -33,7 +33,7 @@ |
34 | 34 | // Show the results |
35 | 35 | $s = "<table class=\"securepoll-results\">\n"; |
36 | 36 | |
37 | | - foreach ( $this->tally as $oid ) { |
| 37 | + foreach ( $this->tally as $oid => $rank ) { |
38 | 38 | $option = $this->optionsById[$oid]; |
39 | 39 | $s .= '<tr><td>' . $option->parseMessageInline( 'text' ) . "</td>\n" . |
40 | 40 | '<td>' . $this->tally[$oid] . "</td>\n" . |
— | — | @@ -46,7 +46,7 @@ |
47 | 47 | function getTextResult() { |
48 | 48 | // Calculate column width |
49 | 49 | $width = 10; |
50 | | - foreach ( $this->tally as $oid ) { |
| 50 | + foreach ( $this->tally as $oid => $rank ) { |
51 | 51 | $option = $this->optionsById[$oid]; |
52 | 52 | $width = max( $width, strlen( $option->getMessage( 'text' ) ) ); |
53 | 53 | } |
— | — | @@ -60,7 +60,7 @@ |
61 | 61 | if ( $qtext !== '' ) { |
62 | 62 | $s .= wordwrap( $qtext ) . "\n"; |
63 | 63 | } |
64 | | - foreach ( $this->tally as $oid ) { |
| 64 | + foreach ( $this->tally as $oid => $rank ) { |
65 | 65 | $option = $this->optionsById[$oid]; |
66 | 66 | $otext = $option->getMessage( 'text' ); |
67 | 67 | if ( strlen( $otext ) > $width ) { |
Index: trunk/extensions/SecurePoll/includes/talliers/HistogramRangeTallier.php |
— | — | @@ -69,7 +69,7 @@ |
70 | 70 | Xml::tags( 'td', array( 'class' => 'securepoll-results-row-heading' ), |
71 | 71 | $optionLabels[$oid] ) . |
72 | 72 | "\n"; |
73 | | - foreach ( $labels as $score ) { |
| 73 | + foreach ( $labels as $score => $label ) { |
74 | 74 | $s .= Xml::element( 'td', array(), $this->histogram[$oid][$score] ) . "\n"; |
75 | 75 | } |
76 | 76 | $s .= Xml::element( 'td', array(), $average ) . "\n"; |
Index: trunk/extensions/SecurePoll/includes/main/Context.php |
— | — | @@ -197,7 +197,7 @@ |
198 | 198 | if ( isset( $this->messagesLoaded[$lang] ) ) { |
199 | 199 | $cacheRow = $this->messagesLoaded[$lang]; |
200 | 200 | $uncachedIds = array_flip( $ids ); |
201 | | - foreach ( $uncachedIds as $id ) { |
| 201 | + foreach ( $uncachedIds as $id => $unused ) { |
202 | 202 | if ( isset( $cacheRow[$id] ) ) { |
203 | 203 | unset( $uncachedIds[$id] ); |
204 | 204 | } |