Index: trunk/phase3/includes/Linker.php |
— | — | @@ -684,11 +684,11 @@ |
685 | 685 | * @return String |
686 | 686 | */ |
687 | 687 | public function makeBrokenImageLinkObj( $title, $text = '', $query = '', $trail = '', $prefix = '', $time = false ) { |
688 | | - global $wgEnableUploads, $wgUploadNavigationUrl; |
| 688 | + global $wgEnableUploads, $wgUploadMissingFileUrl; |
689 | 689 | if( $title instanceof Title ) { |
690 | 690 | wfProfileIn( __METHOD__ ); |
691 | 691 | $currentExists = $time ? ( wfFindFile( $title ) != false ) : false; |
692 | | - if( ( $wgUploadNavigationUrl || $wgEnableUploads ) && !$currentExists ) { |
| 692 | + if( ( $wgUploadMissingFileUrl || $wgEnableUploads ) && !$currentExists ) { |
693 | 693 | if( $text == '' ) |
694 | 694 | $text = htmlspecialchars( $title->getPrefixedText() ); |
695 | 695 | |
— | — | @@ -724,13 +724,13 @@ |
725 | 725 | * @return String: urlencoded URL |
726 | 726 | */ |
727 | 727 | protected function getUploadUrl( $destFile, $query = '' ) { |
728 | | - global $wgUploadNavigationUrl; |
| 728 | + global $wgUploadMissingFileUrl; |
729 | 729 | $q = 'wpDestFile=' . $destFile->getPartialUrl(); |
730 | 730 | if( $query != '' ) |
731 | 731 | $q .= '&' . $query; |
732 | 732 | |
733 | | - if( $wgUploadNavigationUrl ) { |
734 | | - return wfAppendQuery( $wgUploadNavigationUrl, $q ); |
| 733 | + if( $wgUploadMissingFileUrl ) { |
| 734 | + return wfAppendQuery( $wgUploadMissingFileUrl, $q ); |
735 | 735 | } else { |
736 | 736 | $upload = SpecialPage::getTitleFor( 'Upload' ); |
737 | 737 | return $upload->getLocalUrl( $q ); |
Index: trunk/phase3/includes/DefaultSettings.php |
— | — | @@ -436,13 +436,17 @@ |
437 | 437 | * Useful if you want to use a shared repository by default |
438 | 438 | * without disabling local uploads (use $wgEnableUploads = false for that) |
439 | 439 | * e.g. $wgUploadNavigationUrl = 'http://commons.wikimedia.org/wiki/Special:Upload'; |
440 | | - * |
441 | | - * This also affects images inline images that do not exist. In that case the URL will get |
442 | | - * (?|&)wpDestFile=<filename> appended to it as appropriate. |
443 | 440 | */ |
444 | 441 | $wgUploadNavigationUrl = false; |
445 | 442 | |
446 | 443 | /** |
| 444 | + * Point the upload link for missing files to an external URL, as with |
| 445 | + * $wgUploadNavigationUrl. The URL will get (?|&)wpDestFile=<filename> |
| 446 | + * appended to it as appropriate. |
| 447 | + */ |
| 448 | +$wgUploadMissingFileUrl = false; |
| 449 | + |
| 450 | +/** |
447 | 451 | * Give a path here to use thumb.php for thumbnail generation on client request, instead of |
448 | 452 | * generating them on render and outputting a static URL. This is necessary if some of your |
449 | 453 | * apache servers don't have read/write access to the thumbnail path. |
Index: trunk/phase3/RELEASE-NOTES |
— | — | @@ -46,6 +46,8 @@ |
47 | 47 | uploads in. |
48 | 48 | * IBM DB2 database no longer uses the db specific $wgDBport_db2 variable but the |
49 | 49 | normal $wgDBport. |
| 50 | +* The upload link for missing files can now be set separately from the |
| 51 | + navigation link with $wgUploadMissingFileUrl. |
50 | 52 | |
51 | 53 | === New features in 1.17 === |
52 | 54 | * (bug 10183) Users can now add personal styles and scripts to all skins via |