====== WordPressExporter ======
**Layer:** ''Utility'' · **Source:** ''lib/utility/export-wordpress.php:16'' (lines 16–294)
----
class WordPressExporter
WordPress WXR Exporter Utility
Exports Blogware content to WordPress eXtended RSS (WXR) format
======= Docblock Metadata =======
^ Tag ^ Value ^
| ''@category'' | Utility |
| ''@author'' | M.Noermoehammad |
| ''@license'' | MIT |
| ''@version'' | 1.0 |
| ''@since'' | Since Release 1.0 |
======= Inheritance =======
//No parent, interface or trait. This is a root type.//
======= Constants (0) =======
//None.//
======= Properties (3) =======
^ Visibility ^ Type ^ Name ^ Default ^ Line ^
| ''private'' | ''(untyped)'' | ''$wxrVersion'' | '''1.2''' | 18 |
| ''private'' | ''(untyped)'' | ''$siteUrl'' | | 19 |
| ''private'' | ''(untyped)'' | ''$siteTitle'' | | 20 |
======= Methods (8) =======
^ Visibility ^ Method ^ Summary ^ Line ^
| public | ''__construct()'' | (undocumented) | 22 |
| public | ''export()'' | Export content to WXR format | 39 |
| private | ''getAuthors()'' | Get authors for export | 155 |
| private | ''getCategories()'' | Get categories for export | 182 |
| private | ''getPosts()'' | Get posts for export | 200 |
| private | ''getPostCategories()'' | Get categories associated with a post | 244 |
| private | ''getPostTags()'' | Get tags from post_tags field (comma-separated) | 263 |
| private | ''getPostComments()'' | Get comments for a post | 282 |
======== __construct() ========
public function __construct()
//lines 22–29 (8)//
//Takes no parameters.//
======== export() ========
public function export(&$exportStats, $authorId = null)
//lines 39–147 (109)//
Export content to WXR format
^ Parameter ^ Type ^ Default ^ Description ^
| ''$exportStats (by reference)'' | ''(untyped)'' | //required// | Reference to stats array to update |
| ''$authorId'' | ''(untyped)'' | ''null'' | Filter by author ID (null for all) |
**Returns:** ''(none declared)'' — string WXR XML content
**Throws:** ''ExportException''
======== getAuthors() ========
private function getAuthors($authorId = null)
//lines 155–175 (21)//
Get authors for export
^ Parameter ^ Type ^ Default ^ Description ^
| ''$authorId'' | ''(untyped)'' | ''null'' | //none// |
**Returns:** ''(none declared)'' — array
======== getCategories() ========
private function getCategories()
//lines 182–192 (11)//
Get categories for export
//Takes no parameters.//
**Returns:** ''(none declared)'' — array
======== getPosts() ========
private function getPosts($authorId = null)
//lines 200–236 (37)//
Get posts for export
^ Parameter ^ Type ^ Default ^ Description ^
| ''$authorId'' | ''(untyped)'' | ''null'' | //none// |
**Returns:** ''(none declared)'' — array
======== getPostCategories() ========
private function getPostCategories($postId)
//lines 244–255 (12)//
Get categories associated with a post
^ Parameter ^ Type ^ Default ^ Description ^
| ''$postId'' | ''(untyped)'' | //required// | //none// |
**Returns:** ''(none declared)'' — array
======== getPostTags() ========
private function getPostTags($tagsField)
//lines 263–274 (12)//
Get tags from post_tags field (comma-separated)
^ Parameter ^ Type ^ Default ^ Description ^
| ''$tagsField'' | ''(untyped)'' | //required// | //none// |
**Returns:** ''(none declared)'' — array
======== getPostComments() ========
private function getPostComments($postId)
//lines 282–293 (12)//
Get comments for a post
^ Parameter ^ Type ^ Default ^ Description ^
| ''$postId'' | ''(untyped)'' | //required// | //none// |
**Returns:** ''(none declared)'' — array
----
//This page is generated from source by 'tools/gendoc'. Edits will be overwritten.//