Où puis-je télécharger le schéma (ou DTD) pour la mise en page du format de fichier d'importation/exportation WordPress?
Il semble s'agir d'un flux RSS http://en.wikipedia.org/wiki/RSS complété par certaines extensions de WordPress. Malheureusement, cela ne s'applique qu'aux publications et aux pages. Je pensais l'utiliser pour migrer des données de PHP-Fusion vers WordPress, mais ce ne serait qu'une solution partielle.
J'ai essayé quelques-uns des naemspaces ci-dessous dans le navigateur pour voir s'ils me donnaient un schéma ou une DTD, mais ce n'est pas le cas.
Voici un exemple:
<rss version="2.0"
xmlns:excerpt="http://wordpress.org/export/1.0/excerpt/"
- xmlns:content="http://purl.org/rss/1.0/modules/content/"
xmlns:wfw="http://wellformedweb.org/CommentAPI/"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:wp="http://wordpress.org/export/1.0/"
>
<channel>
<title>MrHebrew.com</title>
<link>http://mrhebrew.com</link>
<description>My Site Descr</description>
<pubDate>Wed, 05 Jan 2011 05:54:07 +0000</pubDate>
<generator>http://wordpress.org/?v=3.0.3</generator>
<language>en</language>
<wp:wxr_version>1.0</wp:wxr_version>
<wp:base_site_url>http://mrhebrew.com</wp:base_site_url>
<wp:base_blog_url>http://mrhebrew.com</wp:base_blog_url>
<wp:category><wp:category_nicename>adam-and-eve</wp:category_nicename><wp:category_parent></wp:category_parent><wp:cat_name><![CDATA[Adam and Eve]]></wp:cat_name></wp:category>
<wp:category><wp:category_nicename>book-of-joshua</wp:category_nicename><wp:category_parent></wp:category_parent><wp:cat_name><![CDATA[Book of Joshua]]></wp:cat_name></wp:category>
<wp:tag><wp:tag_slug>jeremiah</wp:tag_slug><wp:tag_name><![CDATA[Jeremiah]]></wp:tag_name></wp:tag>
<wp:tag><wp:tag_slug>joshua</wp:tag_slug><wp:tag_name><![CDATA[Joshua]]></wp:tag_name></wp:tag>
<wp:tag><wp:tag_slug>judges</wp:tag_slug><wp:tag_name><![CDATA[Judges]]></wp:tag_name></wp:tag>
<wp:tag><wp:tag_slug>king-saul</wp:tag_slug><wp:tag_name><![CDATA[King Saul]]></wp:tag_name></wp:tag>
<item>
<title>Another Possible Punctuation Changes Meaning Entirely</title>
<link>http://mrhebrew.com/?p=136</link>
<pubDate>Wed, 05 Jan 2011 05:52:49 +0000</pubDate>
<dc:creator><![CDATA[Administrator]]></dc:creator>
<category><![CDATA[Isaiah]]></category>
<category domain="category" nicename="isaiah"><![CDATA[Isaiah]]></category>
<category><![CDATA[Punctuation]]></category>
<category domain="category" nicename="punctuation"><![CDATA[Punctuation]]></category>
<category domain="tag"><![CDATA[punctuation]]></category>
<category domain="tag" nicename="punctuation-2"><![CDATA[punctuation]]></category>
<category domain="tag"><![CDATA[question-mark]]></category>
<category domain="tag" nicename="question-mark"><![CDATA[question-mark]]></category>
<guid isPermaLink="false">http://mrhebrew.com/?p=136</guid>
<description></description>
<content:encoded><![CDATA[
text of blog here
]]></content:encoded>
<excerpt:encoded><![CDATA[]]></excerpt:encoded>
<wp:post_id>136</wp:post_id>
<wp:post_date>2011-01-05 05:52:49</wp:post_date>
<wp:post_date_gmt>2011-01-05 05:52:49</wp:post_date_gmt>
<wp:comment_status>open</wp:comment_status>
<wp:ping_status>open</wp:ping_status>
<wp:post_name>another-possible-punctuation-changes-meaning-entirely</wp:post_name>
<wp:status>publish</wp:status>
<wp:post_parent>0</wp:post_parent>
<wp:menu_order>0</wp:menu_order>
<wp:post_type>post</wp:post_type>
<wp:post_password></wp:post_password>
<wp:is_sticky>0</wp:is_sticky>
<wp:postmeta>
<wp:meta_key>_edit_lock</wp:meta_key>
<wp:meta_value><![CDATA[1294206847]]></wp:meta_value>
</wp:postmeta>
<wp:postmeta>
<wp:meta_key>_edit_last</wp:meta_key>
<wp:meta_value><![CDATA[1]]></wp:meta_value>
</wp:postmeta>
<wp:postmeta>
<wp:meta_key>_encloseme</wp:meta_key>
<wp:meta_value><![CDATA[1]]></wp:meta_value>
</wp:postmeta>
<wp:postmeta>
<wp:meta_key>_wp_old_slug</wp:meta_key>
<wp:meta_value><![CDATA[]]></wp:meta_value>
</wp:postmeta>
<wp:postmeta>
<wp:meta_key>_pingme</wp:meta_key>
<wp:meta_value><![CDATA[1]]></wp:meta_value>
</wp:postmeta>
<wp:postmeta>
<wp:meta_key>_wp_old_slug</wp:meta_key>
<wp:meta_value><![CDATA[another-possible-punctuation-changs-meaning-entirely]]></wp:meta_value>
</wp:postmeta>
<wp:comment>
<wp:comment_id>267</wp:comment_id>
<wp:comment_author><![CDATA[sex tubes]]></wp:comment_author>
<wp:comment_author_email>[email protected]</wp:comment_author_email>
<wp:comment_author_url>http://41tube.com</wp:comment_author_url>
<wp:comment_author_IP>89.149.244.89</wp:comment_author_IP>
<wp:comment_date>2011-01-08 20:26:32</wp:comment_date>
<wp:comment_date_gmt>2011-01-08 20:26:32</wp:comment_date_gmt>
<wp:comment_content><![CDATA[I can see the logic in your argument but I think you've painted your strokes]]></wp:comment_content>
<wp:comment_approved>spam</wp:comment_approved>
<wp:comment_type></wp:comment_type>
<wp:comment_parent>0</wp:comment_parent>
<wp:comment_user_id>0</wp:comment_user_id>
</wp:comment>
</item>
</channel>
</rss>
Autant que je sache, personne ne l’a jamais documentée [publiquement] et toutes les questions à ce sujet se posent "comme un RSS, vous voulez de la documentation - faites-le vous-même".
Vous trouverez ici un exemple avec les balises les plus importantes d'une DTD utilisée par exemple par InDesign à des fins de test. En lisant le XML WordPress exporté (WP v3.2.1), il est facile de choisir et d’ajouter les bonnes balises au bon endroit.
<?xml version="1.0" encoding="UTF-8" ?>
<!ELEMENT rss ( channel ) >
<!ELEMENT channel ( item+ ) >
<!ELEMENT item ( title, link, pubDate, dc:creator, content:encoded ) >
<!ELEMENT title ( #PCDATA ) >
<!ELEMENT link ( #PCDATA ) >
<!ELEMENT pubDate ( #PCDATA ) >
<!ELEMENT dc:creator (#PCDATA ) >
<!ELEMENT content:encoded ( #PCDATA ) >