Inheritance diagram for Post:
Collaboration diagram for Post:Public Member Functions | |
| __construct ($paramarray=array()) | |
| insert () | |
| update ($minor=true) | |
| delete () | |
| publish () | |
| __get ($name) | |
| __set ($name, $value) | |
| __call ($name, $args) | |
| get_form ($context) | |
| comment_form ($context= 'public') | |
| css_class ($append=array()) | |
| get_url_args () | |
| ascend ($params=null) | |
| descend ($params=null) | |
| content_type () | |
| create_default_tokens () | |
| has_tokens ($tokens) | |
| add_tokens ($tokens) | |
| delete_tokens () | |
| remove_tokens ($tokens) | |
| set_tokens ($tokens) | |
| get_tokens () | |
| get_access ($user=null) | |
Static Public Member Functions | |
| static | list_active_post_types ($refresh=false) |
| static | list_all_post_types ($refresh=false) |
| static | activate_post_type ($type) |
| static | deactivate_post_type ($type) |
| static | list_post_statuses ($all=true, $refresh=false) |
| static | status ($name) |
| static | status_name ($status) |
| static | type ($name) |
| static | type_name ($type) |
| static | add_new_type ($type, $active=true) |
| static | delete_post_type ($type) |
| static | add_new_status ($status, $internal=false) |
| static | delete_post_status ($status) |
| static | default_fields () |
| static | get ($paramarray=array()) |
| static | create ($paramarray) |
Static Public Attributes | |
| static | $post_status_list = array() |
| static | $post_type_list_active = array() |
| static | $post_type_list_all = array() |
Protected Attributes | |
| $url_args | |
Includes an instance of the PostInfo class; for holding inforecords about a Post If the Post object describes an existing post; use the internal info object to get, set, unset and test for existence (isset) of info records. $this->info= new PostInfo( 1 ); // Info records of post with id = 1 $this->info->option1= "blah"; // set info record with name "option1" to value "blah" $info_value= $this->info->option1; // get value of info record with name "option1" into variable $info_value if ( isset ( $this->info->option1 ) ) // test for existence of "option1" unset ( $this->info->option1 ); // delete "option1" info record
Definition at line 21 of file post.php.
| Post::__construct | ( | $ | paramarray = array() |
) |
| Post::__call | ( | $ | name, | |
| $ | args | |||
| ) |
| Post::__get | ( | $ | name | ) |
function __get Overrides QueryRecord __get to implement custom object properties
| string | Name of property to return |
| Post::__set | ( | $ | name, | |
| $ | value | |||
| ) |
function __set Overrides QueryRecord __set to implement custom object properties
| string | Name of property to return |
| static Post::activate_post_type | ( | $ | type | ) | [static] |
Activate an existing post type
| string | The post type to activate |
Definition at line 89 of file post.php.
Referenced by add_new_type().
| static Post::add_new_status | ( | $ | status, | |
| $ | internal = false | |||
| ) | [static] |
inserts a new post status into the database, if it doesn't exist
| string | The name of the new post status | |
| bool | Whether this status is for internal use only. If true, this status will NOT be presented to the user |
Definition at line 295 of file post.php.
Referenced by Undelete::action_plugin_activation().
| static Post::add_new_type | ( | $ | type, | |
| $ | active = true | |||
| ) | [static] |
| Post::add_tokens | ( | $ | tokens | ) |
Add a token to a post
| mixed | $token The name of the permission to add, or an array of permissions to add |
Definition at line 1245 of file post.php.
Referenced by create_default_tokens().
| Post::ascend | ( | $ | params = null |
) |
| Post::comment_form | ( | $ | context = 'public' |
) |
| Post::content_type | ( | ) |
Return the content type of this object
Implements IsContent.
Definition at line 1208 of file post.php.
Referenced by __get(), create_default_tokens(), get_access(), get_form(), get_url_args(), and insert().
| static Post::create | ( | $ | paramarray | ) | [static] |
| Post::create_default_tokens | ( | ) |
| Post::css_class | ( | $ | append = array() |
) |
| static Post::deactivate_post_type | ( | $ | type | ) | [static] |
| static Post::default_fields | ( | ) | [static] |
Return the defined database columns for a Post.
Definition at line 329 of file post.php.
Referenced by Posts::get(), and Posts::publish_scheduled_posts().
| Post::delete | ( | ) |
function delete Deletes an existing post
Definition at line 617 of file post.php.
Referenced by delete_post_type(), delete_tokens(), remove_tokens(), and set_tokens().
| static Post::delete_post_type | ( | $ | type | ) | [static] |
removes a post type from the database, if it exists and there are no posts of the type
| string | The post type name |
| Post::delete_tokens | ( | ) |
| Post::descend | ( | $ | params = null |
) |
| static Post::get | ( | $ | paramarray = array() |
) | [static] |
Return a single requested post.
$post= Post::get( array( 'slug' => 'wooga' ) );
| array | $paramarray An associative array of parameters, or a querystring |
Definition at line 379 of file post.php.
Referenced by FeedbackHandler::act_add_comment(), AdminHandler::act_admin(), FeedbackHandler::add_comment(), comment_form(), AtomHandler::delete_entry(), AtomHandler::get_comments(), AtomHandler::get_entry(), AdminPostsHandler::get_publish(), AdminPostsHandler::post_delete_post(), AtomHandler::put_entry(), and Pingback::xmlrpc_pingback__ping().
| Post::get_access | ( | $ | user = null |
) |
| Post::get_form | ( | $ | context | ) |
| Post::get_tokens | ( | ) |
Returns an array of token ids that are associated with this post Also initializes the internal token array for use by other token operations
Definition at line 1306 of file post.php.
Referenced by add_tokens(), get_access(), has_tokens(), and remove_tokens().
| Post::get_url_args | ( | ) |
| Post::has_tokens | ( | $ | tokens | ) |
| Post::insert | ( | ) |
function insert Saves a new post to the posts table
Definition at line 518 of file post.php.
Referenced by add_tokens(), and set_tokens().
| static Post::list_active_post_types | ( | $ | refresh = false |
) | [static] |
returns an associative array of active post types
| bool | whether to force a refresh of the cached values |
Definition at line 42 of file post.php.
Referenced by CoreBlocks::action_block_form_recent_posts(), add_new_type(), ACL::create_default_tokens(), deactivate_post_type(), delete_post_type(), Posts::get(), Comments::get(), AdminHandler::get_main_menu(), AdminPostsHandler::post_posts(), Posts::search_to_get(), type(), and type_name().
| static Post::list_all_post_types | ( | $ | refresh = false |
) | [static] |
returns an associative array of all post types
| bool | whether to force a refresh of the cached values |
Definition at line 64 of file post.php.
Referenced by activate_post_type(), add_new_type(), and delete_post_type().
| static Post::list_post_statuses | ( | $ | all = true, |
|
| $ | refresh = false | |||
| ) | [static] |
returns an associative array of post statuses
| mixed | $all true to list all statuses, not just external ones, Post to list external and any that match the Post status | |
| boolean | $refresh true to force a refresh of the cached values |
Definition at line 131 of file post.php.
Referenced by add_new_status(), get_form(), AdminPostsHandler::get_publish(), AdminPostsHandler::post_posts(), Posts::search_to_get(), status(), and status_name().
| Post::publish | ( | ) |
| Post::remove_tokens | ( | $ | tokens | ) |
| Post::set_tokens | ( | $ | tokens | ) |
| static Post::status | ( | $ | name | ) | [static] |
returns the integer value of the specified post status, or false
| mixed | a post status name or value |
Definition at line 164 of file post.php.
Referenced by __get(), AdminHandler::act_admin(), Theme::act_display(), Charcoal::action_block_content_charcoal_menu(), K2::action_block_content_k2_menu(), CoreBlocks::action_block_content_recent_comments(), Pingback::action_post_insert_after(), Pingback::action_post_update_after(), AtomHandler::add_posts(), Mzingi::add_template_vars(), default_fields(), delete(), AtomHandler::delete_entry(), Undelete::filter_post_delete_allow(), get(), Posts::get(), AtomHandler::get_collection(), AdminDashboardHandler::get_dashboard(), AtomHandler::get_entry(), get_form(), AdminPostsHandler::get_publish(), insert(), AtomHandler::post_collection(), AdminPostsHandler::post_delete_post(), publish(), Posts::publish_scheduled_posts(), AtomHandler::put_entry(), Tag::rewrite_tag_exists(), Charcoal::theme_show_tags(), update(), and Posts::update_scheduled_posts_cronjob().
| static Post::status_name | ( | $ | status | ) | [static] |
| static Post::type | ( | $ | name | ) | [static] |
returns the integer value of the specified post type, or false
| mixed | a post type name or number |
Definition at line 198 of file post.php.
Referenced by Theme::act_display_date(), Theme::act_display_entries(), Theme::act_display_home(), Theme::act_display_tag(), Charcoal::add_template_vars(), default_fields(), delete_post_type(), CoreDashModules::filter_dash_module_latest_entries(), Posts::get(), Tags::get_by_frequency(), AtomHandler::get_collection(), AdminDashboardHandler::get_dashboard(), and AdminPostsHandler::get_publish().
| static Post::type_name | ( | $ | type | ) | [static] |
returns the friendly name of a post type, or null
| mixed | a post type number, or name |
Definition at line 215 of file post.php.
Referenced by __get(), AdminHandler::act_admin(), Theme::act_display(), content_type(), get_access(), Comment::get_access(), AtomHandler::get_comments(), get_form(), AdminPostsHandler::get_publish(), get_url_args(), insert(), and AdminPostsHandler::post_delete_post().
| Post::update | ( | $ | minor = true |
) |
1.7.1