mirror of
https://github.com/WordPress/WordPress.git
synced 2025-02-22 15:31:42 +01:00
Fix for bug #0000023: import-mt will no longer confuse multiple dashes in a post with the seperator marking a new entry.
git-svn-id: http://svn.automattic.com/wordpress/trunk@1431 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
33900801ce
commit
0c388147a9
@ -66,9 +66,10 @@ set_magic_quotes_runtime(0);
|
||||
$datalines = file(MTEXPORT); // Read the file into an array
|
||||
$importdata = implode('', $datalines); // squish it
|
||||
$importdata = preg_replace("/(\r\n|\n|\r)/", "\n", $importdata);
|
||||
$importdata = preg_replace("/--------\nAUTHOR/", "--MT-ENTRY--\nAUTHOR", $importdata);
|
||||
$authors = array();
|
||||
$temp = array();
|
||||
$posts = explode("--------", $importdata);
|
||||
$posts = explode("--MT-ENTRY--", $importdata);
|
||||
|
||||
function users_form($n) {
|
||||
global $wpdb, $testing;
|
||||
@ -175,8 +176,8 @@ for ($x = 1; $x < $y; $x++) {
|
||||
$datalines = file(MTEXPORT); // Read the file into an array
|
||||
$importdata = implode('', $datalines); // squish it
|
||||
$importdata = preg_replace("/(\r\n|\n|\r)/", "\n", $importdata);
|
||||
|
||||
$posts = explode("--------", $importdata);
|
||||
$importdata = preg_replace("/--------\nAUTHOR/", "--MT-ENTRY--\nAUTHOR", $importdata);
|
||||
$posts = explode("--MT-ENTRY--", $importdata);
|
||||
$i = -1;
|
||||
echo "<ol>";
|
||||
foreach ($posts as $post) { if ('' != trim($post)) {
|
||||
|
Loading…
Reference in New Issue
Block a user