Index: trunk/tools/commonsapi/commonsapi.php |
— | — | @@ -141,7 +141,7 @@ |
142 | 142 | foreach ( $matches AS $m ) { |
143 | 143 | $t = array_pop ( explode ( $m , $text , 2 ) ) ; |
144 | 144 | $title = array () ; |
145 | | - preg_match ( '/\s+title="[^"]*"/' , $t , &$title ) ; |
| 145 | + preg_match ( '/\s+title="[^"]*"/' , $t , $title ) ; |
146 | 146 | $title = $title[0] ; |
147 | 147 | $title = array_pop ( explode ( 'title="' , $title , 2 ) ) ; |
148 | 148 | $title = substr ( $title , 0 , -1 ) ; |
— | — | @@ -164,7 +164,7 @@ |
165 | 165 | function try_fileinfo_template ( $text ) { |
166 | 166 | global $titles ; |
167 | 167 | $matches = array () ; |
168 | | - preg_match_all ( '/th[^>]+id="fileinfotpl_[^"]+"/' , $text , &$matches ) ; |
| 168 | + preg_match_all ( '/th[^>]+id="fileinfotpl_[^"]+"/' , $text , $matches ) ; |
169 | 169 | $matches = $matches[0] ; |
170 | 170 | |
171 | 171 | if ( count ( $matches ) == 0 ) return false ; |
— | — | @@ -320,7 +320,7 @@ |
321 | 321 | // Detect descriptions in many languages |
322 | 322 | $language_names = array () ; |
323 | 323 | $matches = array () ; |
324 | | -preg_match_all ( '/div\s+class="description [a-z-]+"/' , $text , &$matches ) ; |
| 324 | +preg_match_all ( '/div\s+class="description [a-z-]+"/' , $text , $matches ) ; |
325 | 325 | $matches = $matches[0] ; |
326 | 326 | foreach ( $matches AS $m ) { |
327 | 327 | $tx = explode ( $m , $text ) ; |
— | — | @@ -366,7 +366,7 @@ |
367 | 367 | // Categories |
368 | 368 | $self_made = '' ; |
369 | 369 | $cats = array () ; |
370 | | -preg_match_all ( '/ title="Category:[^"]+"\s*>/' , $text , &$matches ) ; |
| 370 | +preg_match_all ( '/ title="Category:[^"]+"\s*>/' , $text , $matches ) ; |
371 | 371 | $matches = $matches[0] ; |
372 | 372 | foreach ( $matches AS $m ) { |
373 | 373 | $m = array_pop ( explode ( ':' , $m , 2 ) ) ; |
— | — | @@ -416,11 +416,11 @@ |
417 | 417 | $lat = '' ; |
418 | 418 | $lon = '' ; |
419 | 419 | $matches = array () ; |
420 | | -preg_match_all ( '/<span\s+class="latitude">([0-9\.]+)<\/span>([^<]*)/' , $text , &$matches ) ; |
| 420 | +preg_match_all ( '/<span\s+class="latitude">([0-9\.]+)<\/span>([^<]*)/' , $text , $matches ) ; |
421 | 421 | if ( count ( $matches ) == 3 ) { |
422 | 422 | $lat = $matches[1][0] . $matches[2][0] ; |
423 | 423 | $matches = array () ; |
424 | | - preg_match_all ( '/<span\s+class="longitude">([0-9\.]+)<\/span>([^<]*)/' , $text , &$matches ) ; |
| 424 | + preg_match_all ( '/<span\s+class="longitude">([0-9\.]+)<\/span>([^<]*)/' , $text , $matches ) ; |
425 | 425 | if ( count ( $matches ) == 3 ) { |
426 | 426 | $lon = $matches[1][0] . $matches[2][0] ; |
427 | 427 | } |
— | — | @@ -428,7 +428,7 @@ |
429 | 429 | |
430 | 430 | if ( $lat . $lon == '' ) { |
431 | 431 | $matches = array () ; |
432 | | - preg_match_all ( '/<span\s+class="geo"[^>]*>([\-0-9\.]+)\s*;\s*([\-0-9\.]+)<\/span>/' , $text , &$matches ) ; |
| 432 | + preg_match_all ( '/<span\s+class="geo"[^>]*>([\-0-9\.]+)\s*;\s*([\-0-9\.]+)<\/span>/' , $text , $matches ) ; |
433 | 433 | if ( count ( $matches ) == 3 ) { |
434 | 434 | $lat = $matches[1][0] ; |
435 | 435 | $lon = $matches[2][0] ; |