the ParserOutput::getText() post-cache transformations.
* Added a hook, UploadForm:getInitialPageText, to allow extensions to alter the
initial page text for file uploads.
-* (T181651) The info page for File pages now displays the file's base-36 SHA1
+* (T181651) The info page for File pages now displays the file's base-16 SHA1
hash value in the table of basic information.
=== External library changes in 1.31 ===
if ( $title->inNamespace( NS_FILE ) ) {
$fileObj = wfFindFile( $title );
if ( $fileObj !== false ) {
- $output = $fileObj->getSha1();
+ // Convert the base-36 sha1 value obtained from database to base-16
+ $output = Wikimedia\base_convert( $fileObj->getSha1(), 36, 16, 40 );
$pageInfo['header-basic'][] = [
$this->msg( 'pageinfo-file-hash' ),
$output
"pageinfo-category-subcats": "See also:\n* {{msg-mw|Pageinfo-category-pages}}\n* {{msg-mw|Pageinfo-category-files}}",
"pageinfo-category-files": "See also:\n* {{msg-mw|Pageinfo-category-pages}}\n* {{msg-mw|Pageinfo-category-subcats}}",
"pageinfo-user-id": "The numeric ID for a user\n{{Identical|User ID}}",
- "pageinfo-file-hash": "Base-36 SHA-1 value of the file",
+ "pageinfo-file-hash": "Base-16 SHA-1 value of the file",
"markaspatrolleddiff": "{{doc-actionlink}}\nSee also:\n* {{msg-mw|Markaspatrolledtext}}\n{{Identical|Mark as patrolled}}",
"markaspatrolledlink": "{{notranslate}}\nParameters:\n* $1 - link which has text {{msg-mw|Markaspatrolledtext}}",
"markaspatrolledtext": "{{doc-actionlink}}\nSee also:\n* {{msg-mw|Markaspatrolleddiff}}",