$this->dumpForm( $file, $chunkLength, $indent + 1 );
} else {
fseek( $file, $chunkLength, SEEK_CUR );
- if ( $chunkLength & 1 == 1 ) {
+ if ( ( $chunkLength & 1 ) == 1 ) {
// Padding byte between chunks
fseek( $file, 1, SEEK_CUR );
}
private function skipChunk( $file, $chunkLength ) {
fseek( $file, $chunkLength, SEEK_CUR );
- if ( $chunkLength & 0x01 == 1 && !feof( $file ) ) {
+ if ( ( $chunkLength & 0x01 ) == 1 && !feof( $file ) ) {
// padding byte
fseek( $file, 1, SEEK_CUR );
}
EOR;
$txt = preg_replace_callback( $reg, [ $this, 'pageTextCallback' ], $txt );
$txt = "<DjVuTxt>\n<HEAD></HEAD>\n<BODY>\n" . $txt . "</BODY>\n</DjVuTxt>\n";
- $xml = preg_replace( "/<DjVuXML>/", "<mw-djvu><DjVuXML>", $xml, 1 );
- $xml = $xml . $txt . '</mw-djvu>';
+ $xml = preg_replace( "/<DjVuXML>/", "<mw-djvu><DjVuXML>", $xml, 1 ) .
+ $txt .
+ '</mw-djvu>';
}
}