From: Brion Vibber Date: Mon, 14 Mar 2005 13:19:24 +0000 (+0000) Subject: Tweaks for valid output X-Git-Tag: 1.5.0alpha1~607 X-Git-Url: http://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/exercices/modifier.php?a=commitdiff_plain;h=08844302e2853f4b144fa943920f34a38397dab6;p=lhc%2Fweb%2Fwiklou.git Tweaks for valid output --- diff --git a/maintenance/importUseModWiki.php b/maintenance/importUseModWiki.php index 7011bfbb27..46eed2b70d 100644 --- a/maintenance/importUseModWiki.php +++ b/maintenance/importUseModWiki.php @@ -64,7 +64,8 @@ function importPages() 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"> END; @@ -85,7 +86,7 @@ END; function importPageDirectory( $dir, $prefix = "" ) { - echo "\n\n"; + echo "\n\n"; $mydir = opendir( $dir ); while( $entry = readdir( $mydir ) ) { if( preg_match( '/^(.+)\.db$/', $entry, $m ) ) { @@ -154,7 +155,7 @@ function fetchKeptPages( $title ) "minor" => $text["minor"] , "ts" => $section["ts"] , "username" => $section["username"] , "host" => $section["host"] ) ) ); } else { - echo "-- skipped a bad old revision\n"; + echo "\n"; } } return $revisions; @@ -247,8 +248,8 @@ END; $timestamp $username - $comment $minor + $comment $text @@ -308,7 +309,7 @@ function xmlsafe( $string ) { } function xmlCommentSafe( $text ) { - return str_replace( '--', '\\-\\-', xmlsafe( $text ) ); + return str_replace( '--', '\\-\\-', xmlsafe( recodeText( $text ) ) ); }