Index: trunk/phase3/includes/libs/CSSMin.php |
— | — | @@ -126,6 +126,17 @@ |
127 | 127 | $offset = $match[0][1] + strlen( $match[0][0] ); |
128 | 128 | continue; |
129 | 129 | } |
| 130 | + // URLs with absolute paths like /w/index.php need to be expanded |
| 131 | + // to absolute URLs but otherwise left alone |
| 132 | + if ( $match['file'][0] !== '' && $match['file'][0][0] === '/' ) { |
| 133 | + // Replace the file path with an expanded URL |
| 134 | + $source = substr_replace( $source, wfExpandUrl( $match['file'][0] ), |
| 135 | + $match['file'][1], strlen( $match['file'][0] ) |
| 136 | + ); |
| 137 | + // Move the offset to the end of the match, leaving it alone |
| 138 | + $offset = $match[0][1] + strlen( $match[0][0] ); |
| 139 | + continue; |
| 140 | + } |
130 | 141 | // Shortcuts |
131 | 142 | $embed = $match['embed'][0]; |
132 | 143 | $pre = $match['pre'][0]; |