• Resolved woochoo

    (@woochoo)


    [ Moderator note: moved to Fixing WordPress. Please do not use Developing With WordPress for these topics. ]

    I am in the process of migrating a website to WordPress and I’ve created an XML file to import into WordPress. I first exported a sample post from this WP install and used ALL of the nodes to form my importable XML.

    Everything seems fine and I’m only updating nodes that contain article specific content (title, dates, category, copy, etc). The “post_type” and other fields are not being modified because all of what I am importing should be added as a “post.”

    When I try to import a single post to test (via WordPress Importer) I get the following error:

    Failed to import “{article title}”: Invalid post type post

    Here is the post_type node I am importing:

    <wp:post_type>
    <![CDATA[ post ]]>
    </wp:post_type>

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter woochoo

    (@woochoo)

    I forgot to mention, when I import any non-modified file exported directly from WordPress, I get no error, but the post_type field is copied and unchanged directly from these working files.

    I’ve also tried disabling all plugins. Same error.

    Thread Starter woochoo

    (@woochoo)

    I fixed this by removing CDATA from this node inside the XML file I was importing. Not sure why it won’t work with a custom made import, but this did the trick.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Invalid Post Type: “Post”’ is closed to new replies.