Index: trunk/phase3/includes/SpecialUpload.php |
— | — | @@ -133,7 +133,7 @@ |
134 | 134 | */ |
135 | 135 | function processUpload() { |
136 | 136 | global $wgUser, $wgOut, $wgLang, $wgContLang; |
137 | | - global $wgUploadDirectory; |
| 137 | + global $wgUploadDirectory, $wgCopyrightAffirmation; |
138 | 138 | global $wgUseCopyrightUpload, $wgCheckCopyrightUpload; |
139 | 139 | |
140 | 140 | /** |
— | — | @@ -142,7 +142,9 @@ |
143 | 143 | if( trim( $this->mOname ) == '' || empty( $this->mUploadSize ) ) { |
144 | 144 | return $this->mainUploadForm('<li>'.wfMsg( 'emptyfile' ).'</li>'); |
145 | 145 | } |
146 | | - |
| 146 | + |
| 147 | + if ( !$wgCopyrightAffirmation ) |
| 148 | + $this->mUploadAffirm = true; |
147 | 149 | /** |
148 | 150 | * When using detailed copyright, if user filled field, assume he |
149 | 151 | * confirmed the upload |
— | — | @@ -531,7 +533,7 @@ |
532 | 534 | */ |
533 | 535 | function mainUploadForm( $msg='' ) { |
534 | 536 | global $wgOut, $wgUser, $wgLang, $wgUploadDirectory, $wgRequest; |
535 | | - global $wgUseCopyrightUpload; |
| 537 | + global $wgUseCopyrightUpload, $wgCopyrightAffirmation; |
536 | 538 | |
537 | 539 | $cols = intval($wgUser->getOption( 'cols' )); |
538 | 540 | $ew = $wgUser->getOption( 'editwidth' ); |
— | — | @@ -562,12 +564,15 @@ |
563 | 565 | $action = $titleObj->escapeLocalURL(); |
564 | 566 | |
565 | 567 | $encDestFile = htmlspecialchars( $this->mDestFile ); |
| 568 | + $source = null; |
566 | 569 | |
| 570 | + if ( $wgCopyrightAffirmation ) { |
567 | 571 | $source = " |
568 | 572 | <td align='right'> |
569 | 573 | <input tabindex='3' type='checkbox' name='wpUploadAffirm' value='1' id='wpUploadAffirm' /> |
570 | 574 | </td><td align='left'><label for='wpUploadAffirm'>{$ca}</label></td> |
571 | 575 | " ; |
| 576 | + } |
572 | 577 | if ( $wgUseCopyrightUpload ) |
573 | 578 | { |
574 | 579 | $source = " |
Index: trunk/phase3/includes/DefaultSettings.php |
— | — | @@ -1098,6 +1098,10 @@ |
1099 | 1099 | /** Set this to some HTML to override the rights icon with an arbitrary logo */ |
1100 | 1100 | $wgCopyrightIcon = NULL; |
1101 | 1101 | |
| 1102 | +/* Set this to false if you want to get rid of the copyright confirmation |
| 1103 | + * checkbox at Special:Upload */ |
| 1104 | +$wgCopyrightAffirmation = true; |
| 1105 | + |
1102 | 1106 | /** Set this to true if you want detailed copyright information forms on Upload. */ |
1103 | 1107 | $wgUseCopyrightUpload = false; |
1104 | 1108 | |
Index: trunk/phase3/RELEASE-NOTES |
— | — | @@ -317,6 +317,8 @@ |
318 | 318 | "Show preview" and "Show changes" |
319 | 319 | * Special:Statistics now supports action=raw, useful for bots designed to |
320 | 320 | harwest e.g. article counts from multiple wikis. |
| 321 | +* The copyright confirmation box at Special:Upload can now be turned off by setting |
| 322 | + $wgCopyrightAffirmation to a false value in LocalSettings.php |
321 | 323 | |
322 | 324 | === Caveats === |
323 | 325 | |