xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.mediawiki.org/xml/export-0.1/
http://www.mediawiki.org/xml/export-0.1.xsd"
- version="0.1">
+ version="0.1"
+ xml:lang="en">
<!-- generated by importUseModWiki.php -->
END;
function importPageDirectory( $dir, $prefix = "" )
{
- echo "\n<!-- Checking page directory $dir -->\n";
+ echo "\n<!-- Checking page directory " . xmlCommentSafe( $dir ) . " -->\n";
$mydir = opendir( $dir );
while( $entry = readdir( $mydir ) ) {
if( preg_match( '/^(.+)\.db$/', $entry, $m ) ) {
"minor" => $text["minor"] , "ts" => $section["ts"] ,
"username" => $section["username"] , "host" => $section["host"] ) ) );
} else {
- echo "-- skipped a bad old revision\n";
+ echo "<!-- skipped a bad old revision -->\n";
}
}
return $revisions;
<revision>
<timestamp>$timestamp</timestamp>
<contributor><username>$username</username></contributor>
- <comment>$comment</comment>
$minor
+ <comment>$comment</comment>
<text>$text</text>
</revision>
}
function xmlCommentSafe( $text ) {
- return str_replace( '--', '\\-\\-', xmlsafe( $text ) );
+ return str_replace( '--', '\\-\\-', xmlsafe( recodeText( $text ) ) );
}