• This man page refers to b2evo version 0.9.0.11 This is a list of functions you can use in templates. They are sorted by purpose. Note: There is also an obsolete manual page that may still have some interesting info. For more information about how to… more »
  • This page describes the functions used within a [[Skins_2.0|skin template (v 2.x)]] in order to inject the dynamic data into your blog design. (For versions 1.x, please see [[Main.php_functions]]) Below is a listing of available template tags linking t… more »
  • Display priority of item. Example <source lang="php"> $Item->priority( $before = ‘’, $after = ‘’ ); </source> Parameters <table border="1"> <tr> <th>Name</th>… more »
  • This tag inserts the RDF code necessary for automatic trackback discovery. WARNING: this will serve spam bots more than anything else! If you add this to your blog you’ll probably get 10 times more spam and normal users don’t really need th… more »
  • Display item’s title and link to related URL. Example <source lang="php"> $Item->title( array( ‘before’ => ‘’, ‘after’ => ‘’, ‘format&#8217… more »
  • Display tags associated with item. These tags can be edited using edit post form in ‘Tags’ field. Example <source lang="php"> $Item->tags( array( ‘before’ => ‘<div>Tags: ‘,… more »
  • Display raw status of item. Status can be one of the following: published, deprecated, protected, private, draft. Also, see the following tag [[tag_item_status|$Item->status();]] Example <source lang="php"> <?php $Item->… more »
  • Display status of item. Status can be one of the following: published, deprecated, protected, private, draft. Example <source lang="php"> <?php $Item->status( array( ‘before’ => ‘’, &… more »
  • Display link to publish a post if user has edit rights. Example <source lang="php"> $Item->publish_link( $before = ‘ ‘, $after = ‘ ‘, $text = ‘#’, $title = ‘#’, $class = ‘&#821… more »
  • Display permanent link for item. This actually only outputs the URL, to display a real link, use [[tag_item_anchor|$Item->permanent_link();]] Example <source lang="php"> $Item->permanent_url( $mode = ‘’, $blogurl='… more »
  • Links to previous and next post in single post mode. Example <source lang="php"> <?php item_prevnext_links( array( ‘block_start’ => ‘<table class="prevnext_post"><tr>’,… more »
  • Display type of item. Type can be one of the following values: Post, Page, Intro-Main, Intro-Cat, Intro-Tag, Intro-Sub, Intro-All, Podcast, Sidebar link. Example <source lang="php"> $Item->type( $before = ‘’, $after… more »
  • Displays a permanent link to the item. <source lang="php"> $Item->permanent_link( array( ‘before’ => ‘’, ‘after’ => ‘’, ‘text’… more »
  • This tag is useful when workflow is turned on for a blog. Example <source lang="php"> <?php $Item->msgform_link_assigned( $form_url, $before = ‘ ‘, $after = ‘ ‘, $text = ‘#’, $title = &#82… more »
  • Display link to message form for this item’s author. Using this link you can send a message to the author. Example <source lang="php"> <?php $Item->msgform_link( array( ‘before’ => &#8216… more »
  • Display more link for item. Example <source lang="php"> $Item->more_link( array( ‘force_more’ => false, ‘before’ => ‘<p class="bMore">’,… more »
  • Display last modified time (datetime) of item. Example <source lang="php"> $Item->mod_time( $format = ‘’, $useGM = false ); </source> Parameters <table border="1"> <tr> <th>Nam… more »
  • Display last modified date (datetime) of item. Example <source lang="php"> $Item->mod_date( $format = ‘’, $useGM = false ); </source> Parameters <table border="1"> <tr> <th>Nam… more »
  • This tag displays the URL needed for other bloggers to send trackbacks to your blog. This tag does not display anythign if trackback is turned off in the blog settings. A trackback is one of three types of linkbacks, methods for Web authors to request… more »
  • Display a phrase about the number of item views. Example <source lang="php"> $Item->views( $zero = ‘#’, $one = ‘#’, $more = ‘#’ ); </source> Parameters <table border="1"&g… more »
  • Temporarily switch to item’s locale. This is useful on multilingual blogs. It makes sure that added texts like "Read more" are translated to the post’s locale. Of course, it only works if the target language pack is loaded on the… more »
  • This template tag returns the current skin path. Example <source lang="php"> $Skin->get_path(); </source> Parameters This tag does not accept any parameters. Return value This function returns the current skin path. more »
  • This template tag displays a link to subscription screen Example <source lang="php"> user_subs_link( $before = ‘’, $after = ‘’, $link_text = ‘’, $link_title = ‘#’ ); </source>… more »
  • This template tag displays registration link. Example <source lang="php"> user_register_link( $before = ‘’, $after = ‘’, $link_text = ‘’, $link_title = ‘#’, $disp_when_logged_in = false… more »
  • This template tag displays a link to user profile. Example <source lang="php"> user_profile_link( $before = ‘’, $after = ‘’, $link_text = ‘’, $link_title = ‘#’ ); </source> Par… more »
  • This template tag displays link to logout Example <source lang="php"> user_logout_link( $before = ‘’, $after = ‘’, $link_text = ‘’, $link_title = ‘#’ ); </source> Parameters &… more »
  • This template tag displays link to login Example <source lang="php"> user_login_link( $before = ‘’, $after = ‘’, $link_text = ‘’, $link_title = ‘#’ ); </source> Parameters &lt… more »
  • This template tag returns the current skin URL. Example <source lang="php"> $Skin->get_url(); </source> Parameters This tag does not accept any parameters. Return value This function returns the current skin URL. more »
  • This [[TemplateTags|template tag]] adds a widget container to the skin. This container can later be filled with all sorts of Widgets?. Example <source lang="php"> <?php // ———————… more »
  • Display the number of words in the post. Example <source lang="php"> $Item->wordcount(); </source> Parameters This tag does not accept any parameters. Return value This tag displays content only, it does not have a re… more »
  • Display "powered by b2evolution" logo. Example <source lang="php"> powered_by(); </source> Parameters This tag does not accept any parameters. Return value This tag displays content only, it does not have a ret… more »
  • This tag display plugin. Example The calendar plugin. Its code is evo_Calr. <source lang="php"> // Calendar plugin $Plugins->call_by_code( ‘evo_Calr’, array( ‘block_start’ => ‘&#821… more »
  • Display messages collected during single request execution. It can be ‘error’, ‘warning’ messages, and also ’success’ ones. Example <source lang="php"> <?php messages( array( ‘be… more »
  • Displays links to list pages. <source lang="php"> $MainList->page_links( array( ‘block_start’ => ‘ ‘, ‘block_end’ => ‘ ‘, ‘block_single’ => &#8… more »
  • Restore the locale in use before the switch (See [[tag_item_locale_temp_switch|$Item->locale_temp_switch();]]). This tag returns true on success, false on failure (no locale stored before). Example <source lang="php"> locale_rest… more »
  • This template tag returns or displays the current language. Example <source lang="php"> locale_lang( $disp = true ); </source> Parameters <table border="1"> <tr> <th>Name</th> <th… more »
  • This template tag returns or displays the charset of the current locale. Example <source lang="php"> locale_charset( $disp = true ); </source> Parameters <table border="1"> <tr> <th>Name</… more »
  • Display only main category name. Example <source lang="php"> $Item->main_category( $format = ‘htmlbody’ ); </source> Parameters <table border="1"> <tr> <th>Name</th> &… more »
  • Display locale flag image. Example <source lang="php"> <?php $Item->locale_flag( array( ‘before’ => ‘ ‘, ‘after’ => ‘ ‘,… more »
  • This handler includes a "second level" a.k.a. "disp" template based on the value of the $disp variable, i-e: based on the type of content that should be displayed on the current page. more »
  • Display tagline of the blog. This tagline can be edited by the blog owner in the admin interface under ‘Blog Settings > General > Tagline’. Example <source lang="php"> <?php $Blog->tagline( array(… more »
  • This is not in any 2.1 skin (yet), but it works just fine: Display author/creator of item. The tag can display not only author/creator name, but also his/her avatar. Example <source lang="php"> <?php $Item->author( array(… more »
  • Display an anchor for permanent link to refer to. See [[tag_item_permanent_link|$Item->permanent_link();]]. <source lang="php"> $Item->anchor(); </source> Parameters This tag does not accept any parameters. Return v… more »
  • This template tag checks if user is logged in. Example <source lang="php"> is_logged_in(); </source> Parameters This tag does not accept any parameters. Return value This function return true if a user is logged in. more »
  • Display message if there are no any posts. Example <source lang="php"> <?php display_if_empty( array ( ‘before’ => ‘<p class="msg_nothing">’, ‘after’… more »
  • Display credits. You can limit (and even disable) the number of links being displayed by its tag though the Admin interface: ‘Blog Settings > Advanced > Software credits’ Example <source lang="php"> // Display add… more »
  • This template tag displays allowed tags for comment. Example <source lang="php"> comment_allowed_tags( $format = ‘htmlbody’ ); </source> Parameters <table border="1"> <tr> <th>Nam… more »
  • Display name of the blog. This name can be edited by the blog owner in the admin interface under ‘Blog Settings > General > Title’. Example <source lang="php"> <?php $Blog->name( array( ‘b… more »
  • This template tag checks if user can rate this post. Example <source lang="php"> // Return true if user can change rate, false if he/she cannot $Item->can_rate(); </source> Parameters This tag does not accept any param… more »
  • Display long description of the blog. This long description can be edited by the blog owner in the admin interface under ‘Blog Settings > General > Long Description. Example <source lang="php"> <?php $Blog->longd… more »
  • Display a link to the current blog. This tag can display a link to the home if no blog is currently active or a link to a blog if there is an active blog. Example <source lang="php"> blog_home_link( $before = ‘’, $after… more »
  • ‘’b2evolution version 2.4′’ This [[TemplateTags|template tag]] displays the footer text of the current Blog. This footer text can be edited by the blog owner in the admin interface under Blog Settings > Advanced > [[Blog_m… more »
  • This [[TemplateTags|template tag]] displays a link leading to the contact form for the owner of the current Blog. Example <source lang="php"> <?php $Blog->contact_link( array( ‘before’ => ‘ &#82… more »
  • Display application version. Example <source lang="php"> app_version(); </source> Parameters This tag does not accept any parameters. Return value This tag displays content only, it does not have a return value. more »
  • Display a global title matching filter params Example <source lang="php"> <title> <?php request_title( array( ‘auto_pilot’ => ’seo_title’, ‘title_single_before’ => $Blo… more »
  • You can customize the default item feedback by copying the generic /skins/_item_feedback.inc.php file into the current skin folder. more »
  • This template tag checks if user can leave comment on this post or display error. Example <source lang="php"> $Item->can_comment( $before_error = ‘<p><em>’, $after_error = ‘</em></p>&#8217… more »
  • This template tag checks if item can receive pingbacks or trackbacks. Example <source lang="php"> $Item->can_receive_pings(); </source> Parameters This tag does not accept any parameters. Return value This function re… more »
  • Display locale for item. Example <source lang="php"> $Item->locale(); </source> Parameters This tag does not accept any parameters. Return value This tag displays content only, it does not have a return value. Typica… more »
  • Displays feedback moderation link. Feedback includes comments, trackbacks & pingbacks. The tag can display how many non moderated feedbacks there are for an item. If there are not new feedback, which are not moderated by administrator, then it wil… more »
  • Display language name for item. Example <source lang="php"> $Item->language( $format = ‘htmlbody’ ); </source> Parameters <table border="1"> <tr> <th>Name</th> <th&… more »
  • Display language for item. Example <source lang="php"> $Item->lang(); </source> Parameters This tag does not accept any parameters. Return value This tag displays content only, it does not have a return value. Typica… more »
  • To give an example, here is a question from the forum: ‘’Is there any way that I could add something so it shows as:'’ Day 331 of Week 48 Wednesday November, 28 2007 This is the answer: ‘’Find your skin, crack open ind… more »
  • Display the images linked to the current item. Example <source lang="php"> $Item->images( array( ‘before’ => ‘<div>’, ‘before_image’ => ‘&lt… more »
  • This template tag checks if there is any feedback of a given type. Example <source lang="php"> <?php $Item->has_feedback( array( ‘type’ => ‘feedbacks’, ’status… more »
  • ‘’b2evolution version 2.4′’ This [[TemplateTags|template tag]] displays a footer text below the Item. This footer text can be edited by the blog owner in the admin interface under Blog Settings > Advanced > [[Blog_meta_dat… more »
  • Display the attachments/files linked to the current item. Example <source lang="php"> <?php $Item->files( array( ‘before’ => ‘<ul class="bFiles">’, ‘be… more »
  • Displays a link to feedback for an Item. Feedback includes comments, trackbacks & pingbacks. The tag can display how many feedbacks there are for an item. The tag can show all feedbacks or only a specific type like just comments, or just tackbacks… more »
  • List all the category names. Example <source lang="php"> $Item->categories( array( ‘before’ => ‘ ‘, ‘after’ => ‘ ‘, ‘include_main&#… more »
  • Displays link to the RSS or Atom feed for comments on this item. If there are no any comments in the item then it displays nothing. Example <source lang="php"> $Item->feedback_feed_link( $skin = ‘_rss2′, $before = &#8… more »
  • Display extra status of item. Example <source lang="php"> $Item->extra_status( $before = ‘’, $after = ‘’, $format = ‘htmlbody’ ); </source> Parameters <table border="1"&gt… more »
  • This template tag displays a link leading to the edit form where an user can edit post if he has edit rights. Example <source lang="php"> <?php $Item->edit_link( array( ‘before’ => &#8216… more »
  • Display link to deprecate a post if user has edit rights. This is probably only useful for the backoffice or for very advanced/specific uses. Example <source lang="php"> $Item->deprecate_link( $before = ‘ ‘, $after =… more »
  • Display deadline time (datetime) of item. This tag is useful when workflow is turned on for a blog. Example <source lang="php"> $Item->deadline_time( $format = ‘’, $useGM = false ); </source> Parameters <… more »
  • Display deadline date (datetime) of item. This tag is useful when workflow is turned on for a blog. Example <source lang="php"> $Item->deadline_date( $format = ‘’, $useGM = false ); </source> Parameters <… more »
  • This tag displays only the teaser part for a given item. Example <source lang="php"> <?php $Item->content_teaser( array( ‘before’ => ‘’, ‘after’ => &#821… more »
  • This template tag displays registration link. Example <source lang="php"> user_register_link( $before = ‘’, $after = ‘’, $link_text = ‘’, $link_title = ‘#’, $disp_when_logged_in = false… more »

Comments on this chapter


Form is loading...