[ Root ] [ Search ] [ Index ]

PHP Cross Reference of WordPress 3.0.1

Provided by Yoast

title

Body

[close]

/wp-admin/includes/ -> template.php (summary)

Template WordPress Administration API. A Big Mess. Also some neat functions that are nicely written.

File Size: 3950 lines (141 kb)
Included or required: 1 time
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

Walker_Category_Checklist:: (74 methods):
  start_lvl()
  end_lvl()
  start_el()
  end_el()
  wp_category_checklist()
  wp_terms_checklist()
  wp_popular_terms_checklist()
  wp_link_category_checklist()
  _tag_row()
  tag_rows()
  _term_rows()
  wp_manage_posts_columns()
  wp_manage_media_columns()
  wp_manage_pages_columns()
  get_column_headers()
  print_column_headers()
  register_column_headers()
  get_hidden_columns()
  inline_edit_row()
  get_inline_data()
  post_rows()
  _post_row()
  display_page_row()
  page_rows()
  _page_rows()
  user_row()
  _wp_get_comment_list()
  _wp_comment_row()
  wp_comment_reply()
  wp_comment_trashnotice()
  list_meta()
  _list_meta_row()
  meta_form()
  touch_time()
  page_template_dropdown()
  parent_dropdown()
  the_attachment_links()
  wp_dropdown_roles()
  wp_convert_hr_to_bytes()
  wp_convert_bytes_to_hr()
  wp_max_upload_size()
  wp_import_upload_form()
  add_meta_box()
  do_meta_boxes()
  remove_meta_box()
  meta_box_prefs()
  get_hidden_meta_boxes()
  add_settings_section()
  add_settings_field()
  do_settings_sections()
  do_settings_fields()
  add_settings_error()
  get_settings_errors()
  settings_errors()
  manage_columns_prefs()
  find_posts_div()
  the_post_password()
  favorite_actions()
  _draft_or_post_title()
  _admin_search_query()
  iframe_header()
  tb_close()
  iframe_footer()
  _post_states()
  convert_to_screen()
  screen_meta()
  add_contextual_help()
  drag_drop_help()
  plugins_search_help()
  screen_layout()
  screen_options()
  screen_icon()
  compression_test()
  set_current_screen()

Defines 74 functions

  inline_edit_term_row()
  link_cat_row()

Class: Walker_Category_Checklist  - X-Ref

{@internal Missing Short Description}}

start_lvl(&$output, $depth, $args)   X-Ref
No description

end_lvl(&$output, $depth, $args)   X-Ref
No description

start_el(&$output, $category, $depth, $args)   X-Ref
No description

end_el(&$output, $category, $depth, $args)   X-Ref
No description

wp_category_checklist( $post_id = 0, $descendants_and_self = 0, $selected_cats = false, $popular_cats = false, $walker = null, $checked_ontop = true )   X-Ref
{@internal Missing Short Description}}

param: unknown_type $post_id
param: unknown_type $descendants_and_self
param: unknown_type $selected_cats
param: unknown_type $popular_cats

wp_terms_checklist($post_id = 0, $args = array()   X-Ref
Taxonomy independent version of wp_category_checklist

param: int $post_id
param: array $args

wp_popular_terms_checklist( $taxonomy, $default = 0, $number = 10, $echo = true )   X-Ref
{@internal Missing Short Description}}

param: unknown_type $taxonomy
param: unknown_type $default
param: unknown_type $number
param: unknown_type $echo
return: unknown

wp_link_category_checklist( $link_id = 0 )   X-Ref
{@internal Missing Short Description}}

param: unknown_type $link_id

_tag_row( $tag, $level, $taxonomy = 'post_tag' )   X-Ref
{@internal Missing Short Description}}

param: unknown_type $tag
param: unknown_type $class
return: unknown

tag_rows( $page = 1, $pagesize = 20, $searchterms = '', $taxonomy = 'post_tag' )   X-Ref
{@internal Missing Short Description}}

param: unknown_type $page
param: unknown_type $pagesize
param: unknown_type $searchterms
return: unknown

_term_rows( $taxonomy, $terms, &$children, $page = 1, $per_page = 20, &$count, $parent = 0, $level = 0 )   X-Ref
No description

wp_manage_posts_columns( $screen = '')   X-Ref
{@internal Missing Short Description}}

return: unknown

wp_manage_media_columns()   X-Ref
{@internal Missing Short Description}}

return: unknown

wp_manage_pages_columns()   X-Ref
{@internal Missing Short Description}}

return: unknown

get_column_headers($screen)   X-Ref
Get the column headers for a screen

param: string|object $screen The screen you want the headers for
return: array Containing the headers in the format id => UI String

print_column_headers( $screen, $id = true )   X-Ref
{@internal Missing Short Description}}

param: unknown_type $screen
param: unknown_type $id

register_column_headers($screen, $columns)   X-Ref
Register column headers for a particular screen.  The header names will be listed in the Screen Options.

param: string $screen The handle for the screen to add help to.  This is usually the hook name returned by the add_*_page() functions.
param: array $columns An array of columns with column IDs as the keys and translated column names as the values

get_hidden_columns($screen)   X-Ref
{@internal Missing Short Description}}

param: unknown_type $screen

inline_edit_row( $screen )   X-Ref
{@internal Missing Short Description}}

Outputs the quick edit and bulk edit table rows for posts and pages

param: string $screen

get_inline_data($post)   X-Ref
{@internal Missing Short Description}}

param: unknown_type $post

post_rows( $posts = array()   X-Ref
{@internal Missing Short Description}}

param: unknown_type $posts

_post_row($a_post, $pending_comments, $mode)   X-Ref
{@internal Missing Short Description}}

param: unknown_type $a_post
param: unknown_type $pending_comments
param: unknown_type $mode

display_page_row( $page, $level = 0 )   X-Ref
{@internal Missing Short Description}}

param: unknown_type $page
param: unknown_type $level

page_rows($pages, $pagenum = 1, $per_page = 20)   X-Ref
{@internal Missing Short Description}}

param: unknown_type $pages
param: unknown_type $pagenum
param: unknown_type $per_page
return: unknown

_page_rows( &$children_pages, &$count, $parent, $level, $pagenum, $per_page )   X-Ref
Given a top level page ID, display the nested hierarchy of sub-pages
together with paging support

param: unknown_type $children_pages
param: unknown_type $count
param: unknown_type $parent
param: unknown_type $level
param: unknown_type $pagenum
param: unknown_type $per_page

user_row( $user_object, $style = '', $role = '', $numposts = 0 )   X-Ref
Generate HTML for a single row on the users.php admin panel.

param: object $user_object
param: string $style Optional. Attributes added to the TR element.  Must be sanitized.
param: string $role Key for the $wp_roles array.
param: int $numposts Optional. Post count to display for this user.  Defaults to zero, as in, a new user has made zero posts.
return: string

_wp_get_comment_list( $status = '', $s = false, $start, $num, $post = 0, $type = '' )   X-Ref
{@internal Missing Short Description}}

param: string $status Comment status (approved, spam, trash, etc)
param: string $s Term to search for
param: int $start Offset to start at for pagination
param: int $num Maximum number of comments to return
param: int $post Post ID or 0 to return all comments
param: string $type Comment type (comment, trackback, pingback, etc)
return: array [0] contains the comments and [1] contains the total number of comments that match (ignoring $start and $num)

_wp_comment_row( $comment_id, $mode, $comment_status, $checkbox = true, $from_ajax = false )   X-Ref
{@internal Missing Short Description}}

param: unknown_type $comment_id
param: unknown_type $mode
param: unknown_type $comment_status
param: unknown_type $checkbox

wp_comment_reply($position = '1', $checkbox = false, $mode = 'single', $table_row = true)   X-Ref
{@internal Missing Short Description}}

param: unknown_type $position
param: unknown_type $checkbox
param: unknown_type $mode

wp_comment_trashnotice()   X-Ref
Output 'undo move to trash' text for comments


list_meta( $meta )   X-Ref
{@internal Missing Short Description}}

param: unknown_type $meta

_list_meta_row( $entry, &$count )   X-Ref
{@internal Missing Short Description}}

param: unknown_type $entry
param: unknown_type $count
return: unknown

meta_form()   X-Ref
{@internal Missing Short Description}}


touch_time( $edit = 1, $for_post = 1, $tab_index = 0, $multi = 0 )   X-Ref
{@internal Missing Short Description}}

param: unknown_type $edit
param: unknown_type $for_post
param: unknown_type $tab_index
param: unknown_type $multi

page_template_dropdown( $default = '' )   X-Ref
{@internal Missing Short Description}}

param: unknown_type $default

parent_dropdown( $default = 0, $parent = 0, $level = 0 )   X-Ref
{@internal Missing Short Description}}

param: unknown_type $default
param: unknown_type $parent
param: unknown_type $level
return: unknown

the_attachment_links( $id = false )   X-Ref
{@internal Missing Short Description}}

param: unknown_type $id
return: unknown

wp_dropdown_roles( $selected = false )   X-Ref
Print out <option> html elements for role selectors based on $wp_roles

param: string $default slug for the role that should be already selected

wp_convert_hr_to_bytes( $size )   X-Ref
{@internal Missing Short Description}}

param: unknown_type $size
return: unknown

wp_convert_bytes_to_hr( $bytes )   X-Ref
{@internal Missing Short Description}}

param: unknown_type $bytes
return: unknown

wp_max_upload_size()   X-Ref
{@internal Missing Short Description}}

return: unknown

wp_import_upload_form( $action )   X-Ref
Outputs the form used by the importers to accept the data to be imported

param: string $action The action attribute for the form.

add_meta_box($id, $title, $callback, $page, $context = 'advanced', $priority = 'default', $callback_args=null)   X-Ref
Add a meta box to an edit form.

param: string $id String for use in the 'id' attribute of tags.
param: string $title Title of the meta box.
param: string $callback Function that fills the box with the desired content. The function should echo its output.
param: string $page The type of edit page on which to show the box (post, page, link).
param: string $context The context within the page where the boxes should show ('normal', 'advanced').
param: string $priority The priority within the context where the boxes should show ('high', 'low').

do_meta_boxes($page, $context, $object)   X-Ref
Meta-Box template function

param: string $page page identifier, also known as screen identifier
param: string $context box context
param: mixed $object gets passed to the box callback function as first parameter
return: int number of meta_boxes

remove_meta_box($id, $page, $context)   X-Ref
Remove a meta box from an edit form.

param: string $id String for use in the 'id' attribute of tags.
param: string $page The type of edit page on which to show the box (post, page, link).
param: string $context The context within the page where the boxes should show ('normal', 'advanced').

meta_box_prefs($screen)   X-Ref
{@internal Missing Short Description}}

param: unknown_type $screen

get_hidden_meta_boxes( $screen )   X-Ref
Get Hidden Meta Boxes

param: string|object $screen Screen identifier
return: array Hidden Meta Boxes

add_settings_section($id, $title, $callback, $page)   X-Ref
Add a new section to a settings page.

Part of the Settings API. Use this to define new settings sections for an admin page.
Show settings sections in your admin page callback function with do_settings_sections().
Add settings fields to your section with add_settings_field()

The $callback argument should be the name of a function that echoes out any
content you want to show at the top of the settings section before the actual
fields. It can output nothing if you want.

param: string $id Slug-name to identify the section. Used in the 'id' attribute of tags.
param: string $title Formatted title of the section. Shown as the heading for the section.
param: string $callback Function that echos out any content at the top of the section (between heading and fields).
param: string $page The slug-name of the settings page on which to show the section. Built-in pages include 'general', 'reading', 'writing', 'discussion', 'media', etc. Create your own using add_options_page();

add_settings_field($id, $title, $callback, $page, $section = 'default', $args = array()   X-Ref
Add a new field to a section of a settings page

Part of the Settings API. Use this to define a settings field that will show
as part of a settings section inside a settings page. The fields are shown using
do_settings_fields() in do_settings-sections()

The $callback argument should be the name of a function that echoes out the
html input tags for this setting field. Use get_option() to retrive existing
values to show.

param: string $id Slug-name to identify the field. Used in the 'id' attribute of tags.
param: string $title Formatted title of the field. Shown as the label for the field during output.
param: string $callback Function that fills the field with the desired form inputs. The function should echo its output.
param: string $page The slug-name of the settings page on which to show the section (general, reading, writing, ...).
param: string $section The slug-name of the section of the settingss page in which to show the box (default, ...).
param: array $args Additional arguments

do_settings_sections($page)   X-Ref
Prints out all settings sections added to a particular settings page

Part of the Settings API. Use this in a settings page callback function
to output all the sections and fields that were added to that $page with
add_settings_section() and add_settings_field()

param: string $page The slug name of the page whos settings sections you want to output

do_settings_fields($page, $section)   X-Ref
Print out the settings fields for a particular settings section

Part of the Settings API. Use this in a settings page to output
a specific section. Should normally be called by do_settings_sections()
rather than directly.

param: string $page Slug title of the admin page who's settings fields you want to show.
param: section $section Slug title of the settings section who's fields you want to show.

add_settings_error( $setting, $code, $message, $type = 'error' )   X-Ref
Register a settings error to be displayed to the user

Part of the Settings API. Use this to show messages to users about settings validation
problems, missing settings or anything else.

Settings errors should be added inside the $sanitize_callback function defined in
register_setting() for a given setting to give feedback about the submission.

By default messages will show immediately after the submission that generated the error.
Additional calls to settings_errors() can be used to show errors even when the settings
page is first accessed.

param: string $setting Slug title of the setting to which this error applies
param: string $code Slug-name to identify the error. Used as part of 'id' attribute in HTML output.
param: string $message The formatted message text to display to the user (will be shown inside styled <div> and <p>)
param: string $type The type of message it is, controls HTML class. Use 'error' or 'updated'.

get_settings_errors( $setting = '', $sanitize = FALSE )   X-Ref
Fetch settings errors registered by add_settings_error()

Checks the $wp_settings_errors array for any errors declared during the current
pageload and returns them.

If changes were just submitted ($_GET['updated']) and settings errors were saved
to the 'settings_errors' transient then those errors will be returned instead. This
is used to pass errors back across pageloads.

Use the $sanitize argument to manually re-sanitize the option before returning errors.
This is useful if you have errors or notices you want to show even when the user
hasn't submitted data (i.e. when they first load an options page, or in admin_notices action hook)

param: string $setting Optional slug title of a specific setting who's errors you want.
param: boolean $sanitize Whether to re-sanitize the setting value before returning errors.
return: array Array of settings errors

settings_errors( $setting = '', $sanitize = FALSE, $hide_on_update = FALSE )   X-Ref
Display settings errors registered by add_settings_error()

Part of the Settings API. Outputs a <div> for each error retrieved by get_settings_errors().

This is called automatically after a settings page based on the Settings API is submitted.
Errors should be added during the validation callback function for a setting defined in register_setting()

The $sanitize option is passed into get_settings_errors() and will re-run the setting sanitization
on its current value.

The $hide_on_update option will cause errors to only show when the settings page is first loaded.
if the user has already saved new values it will be hidden to avoid repeating messages already
shown in the default error reporting after submission. This is useful to show general errors like missing
settings when the user arrives at the settings page.

param: string $setting Optional slug title of a specific setting who's errors you want.
param: boolean $sanitize Whether to re-sanitize the setting value before returning errors.
param: boolean $hide_on_update If set to true errors will not be shown if the settings page has already been submitted.
return: <type>

manage_columns_prefs( $page )   X-Ref
{@internal Missing Short Description}}

param: unknown_type $page

find_posts_div($found_action = '')   X-Ref
{@internal Missing Short Description}}

param: unknown_type $found_action

the_post_password()   X-Ref
Display the post password.

The password is passed through {@link esc_attr()} to ensure that it
is safe for placing in an html attribute.


favorite_actions( $screen = null )   X-Ref
{@internal Missing Short Description}}


_draft_or_post_title($post_id = 0)   X-Ref
Get the post title.

The post title is fetched and if it is blank then a default string is
returned.

param: int $id The post id. If not supplied the global $post is used.

_admin_search_query()   X-Ref
Display the search query.

A simple wrapper to display the "s" parameter in a GET URI. This function
should only be used when {@link the_search_query()} cannot.


iframe_header( $title = '', $limit_styles = false )   X-Ref
Generic Iframe header for use with Thickbox

param: string $title Title of the Iframe page.
param: bool $limit_styles Limit styles to colour-related styles only (unless others are enqueued).

tb_close()   X-Ref
No description

iframe_footer()   X-Ref
Generic Iframe footer for use with Thickbox


_post_states($post)   X-Ref
No description

convert_to_screen( $screen )   X-Ref
Convert a screen string to a screen object

param: string $screen The name of the screen
return: object An object containing the safe screen name and id

screen_meta($screen)   X-Ref
No description

add_contextual_help($screen, $help)   X-Ref
Add contextual help text for a page

param: string $screen The handle for the screen to add help to.  This is usually the hook name returned by the add_*_page() functions.
param: string $help Arbitrary help text

drag_drop_help()   X-Ref
No description

plugins_search_help()   X-Ref
No description

screen_layout($screen)   X-Ref
No description

screen_options($screen)   X-Ref
No description

screen_icon($screen = '')   X-Ref
No description

compression_test()   X-Ref
Test support for compressing JavaScript from PHP

Outputs JavaScript that tests if compression from PHP works as expected
and sets an option with the result. Has no effect when the current user
is not an administrator. To run the test again the option 'can_compress_scripts'
has to be deleted.


set_current_screen( $id = '' )   X-Ref
Set the current screen object

param: string $id Screen id, optional.

Functions
Functions that are not part of a class:

inline_edit_term_row($type, $taxonomy)   X-Ref
{@internal Missing Short Description}}

param: string $type "edit-tags", "categoried" or "edit-link-categories"
param: string $taxonomy The taxonomy of the row.
return:

link_cat_row( $category, $name_override = false )   X-Ref
{@internal Missing Short Description}}

param: unknown_type $category
param: unknown_type $name_override
return: unknown



Generated: Thu Oct 14 05:12:05 2010 Cross-referenced by PHPXref 0.7