* (bug 25713) SpecialPage::resolveAlias() now normalise spaces to underscores
* (bug 25829) Special:Mypage and Special:Mytalk now forward oldid, diff and dir
parameters
+* (bug 25175) HTML file cache now honor $wgCacheDirectory if
+ $wgFileCacheDirectory is not set
=== API changes in 1.17 ===
* (bug 22738) Allow filtering by action type on query=logevent.
if( !$this->mFileCache ) {
global $wgCacheDirectory, $wgFileCacheDirectory;
- if ( !$wgFileCacheDirectory && !$wgCacheDirectory ) {
+ if ( $wgFileCacheDirectory ) {
+ $dir = $wgFileCacheDirectory;
+ } elseif ( $wgCacheDirectory ) {
+ $dir = "$wgCacheDirectory/html";
+ } else {
throw new MWException( 'Please set $wgCacheDirectory in LocalSettings.php if you wish to use the HTML file cache' );
}
$hash1 = substr( $hash, 0, 1 );
$hash2 = substr( $hash, 0, 2 );
- $this->mFileCache = "{$wgFileCacheDirectory}/{$subdir}{$hash1}/{$hash2}/{$key}.html";
+ $this->mFileCache = "{$dir}/{$subdir}{$hash1}/{$hash2}/{$key}.html";
if( $this->useGzip() ) {
$this->mFileCache .= '.gz';