[ Index ]

PHP Cross Reference of BuddyPress

title

Body

[close]

/src/bp-blogs/ -> bp-blogs-template.php (summary)

BuddyPress Blogs Template Tags.

File Size: 1571 lines (48 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 62 functions

  bp_blogs_slug()
  bp_get_blogs_slug()
  bp_blogs_root_slug()
  bp_get_blogs_root_slug()
  bp_blogs_directory_permalink()
  bp_get_blogs_directory_permalink()
  bp_rewind_blogs()
  bp_has_blogs()
  bp_blogs()
  bp_the_blog()
  bp_blogs_pagination_count()
  bp_get_blogs_pagination_count()
  bp_blogs_pagination_links()
  bp_get_blogs_pagination_links()
  bp_blog_avatar()
  bp_get_blog_avatar()
  bp_blog_permalink()
  bp_get_blog_permalink()
  bp_blog_name()
  bp_get_blog_name()
  bp_blog_id()
  bp_get_blog_id()
  bp_blog_description()
  bp_get_blog_description()
  bp_blog_class()
  bp_get_blog_class()
  bp_blog_last_active()
  bp_get_blog_last_active()
  bp_blog_latest_post()
  bp_get_blog_latest_post()
  bp_blog_latest_post_title()
  bp_get_blog_latest_post_title()
  bp_blog_latest_post_permalink()
  bp_get_blog_latest_post_permalink()
  bp_blog_latest_post_content()
  bp_get_blog_latest_post_content()
  bp_blog_latest_post_featured_image()
  bp_get_blog_latest_post_featured_image()
  bp_blog_latest_post_has_featured_image()
  bp_blog_hidden_fields()
  bp_total_blog_count()
  bp_get_total_blog_count()
  bp_total_blog_count_for_user()
  bp_get_total_blog_count_for_user()
  bp_blog_signup_enabled()
  bp_show_blog_signup_form()
  bp_blogs_signup_blog()
  bp_blogs_validate_blog_signup()
  bp_blogs_validate_blog_form()
  bp_blogs_confirm_blog_signup()
  bp_create_blog_link()
  bp_blogs_blog_tabs()
  bp_directory_blogs_search_form()
  bp_blog_create_button()
  bp_get_blog_create_button()
  bp_blog_create_nav_item()
  bp_get_blog_create_nav_item()
  bp_blog_backcompat_create_nav_item()
  bp_blogs_visit_blog_button()
  bp_get_blogs_visit_blog_button()
  bp_blogs_profile_stats()
  bp_blogs_get_profile_stats()

Functions
Functions that are not part of a class:

bp_blogs_slug()   X-Ref
Output the blogs component slug.

since: 1.5.0

bp_get_blogs_slug()   X-Ref
Return the blogs component slug.

return: string The 'blogs' slug.
since: 1.5.0

bp_blogs_root_slug()   X-Ref
Output the blogs component root slug.

since: 1.5.0

bp_get_blogs_root_slug()   X-Ref
Return the blogs component root slug.

return: string The 'blogs' root slug.
since: 1.5.0

bp_blogs_directory_permalink()   X-Ref
Output blog directory permalink.

since: 1.5.0

bp_get_blogs_directory_permalink()   X-Ref
Return blog directory permalink.

return: string The URL of the Blogs directory.
since: 1.5.0

bp_rewind_blogs()   X-Ref
Rewind the blogs and reset blog index.


bp_has_blogs( $args = '' )   X-Ref
Initialize the blogs loop.

Based on the $args passed, bp_has_blogs() populates the $blogs_template
global, enabling the use of BuddyPress templates and template functions to
display a list of activity items.

param: array|string $args {
return: bool Returns true when blogs are found, otherwise false.

bp_blogs()   X-Ref
Determine if there are still blogs left in the loop.

return: bool Returns true when blogs are found.

bp_the_blog()   X-Ref
Get the current blog object in the loop.

return: object The current blog within the loop.

bp_blogs_pagination_count()   X-Ref
Output the blogs pagination count.

since: 1.0.0

bp_get_blogs_pagination_count()   X-Ref
Get the blogs pagination count.

return: string
since: 2.7.0

bp_blogs_pagination_links()   X-Ref
Output the blogs pagination links.


bp_get_blogs_pagination_links()   X-Ref
Return the blogs pagination links.

return: string HTML pagination links.

bp_blog_avatar( $args = '' )   X-Ref
Output a blog's avatar.

param: array|string $args See {@link bp_get_blog_avatar()}.

bp_get_blog_avatar( $args = '' )   X-Ref
Get a blog's avatar.

At the moment, blog avatars are simply the user avatars of the blog
admin. Filter 'bp_get_blog_avatar_' . $blog_id to customize.

param: array|string $args  {
return: string User avatar string.
since: 2.4.0 Introduced `$title` argument.
since: 6.0.0 Introduced the `$blog_id` & `$admin_user_id` arguments.

bp_blog_permalink()   X-Ref
No description

bp_get_blog_permalink()   X-Ref
No description

bp_blog_name()   X-Ref
Output the name of the current blog in the loop.


bp_get_blog_name()   X-Ref
Return the name of the current blog in the loop.

return: string The name of the current blog in the loop.

bp_blog_id()   X-Ref
Output the ID of the current blog in the loop.

since: 1.7.0

bp_get_blog_id()   X-Ref
Return the ID of the current blog in the loop.

return: int ID of the current blog in the loop.
since: 1.7.0

bp_blog_description()   X-Ref
Output the description of the current blog in the loop.


bp_get_blog_description()   X-Ref
Return the description of the current blog in the loop.

return: string Description of the current blog in the loop.

bp_blog_class( $classes = array()   X-Ref
Output the row class of the current blog in the loop.

param: array $classes Array of custom classes.
since: 1.7.0

bp_get_blog_class( $classes = array()   X-Ref
Return the row class of the current blog in the loop.

param: array $classes Array of custom classes.
return: string Row class of the site.
since: 1.7.0

bp_blog_last_active( $args = array()   X-Ref
Output the last active date of the current blog in the loop.

param: array $args See {@link bp_get_blog_last_active()}.

bp_get_blog_last_active( $args = array()   X-Ref
Return the last active date of the current blog in the loop.

param: array $args {
return: string Last active date.

bp_blog_latest_post( $args = array()   X-Ref
Output the latest post from the current blog in the loop.

param: array $args See {@link bp_get_blog_latest_post()}.

bp_get_blog_latest_post( $args = array()   X-Ref
Return the latest post from the current blog in the loop.

param: array $args {
return: string $retval String of the form 'Latest Post: [link to post]'.

bp_blog_latest_post_title()   X-Ref
Output the title of the latest post on the current blog in the loop.

since: 1.7.0

bp_get_blog_latest_post_title()   X-Ref
Return the title of the latest post on the current blog in the loop.

return: string Post title.
since: 1.7.0

bp_blog_latest_post_permalink()   X-Ref
Output the permalink of the latest post on the current blog in the loop.

since: 1.7.0

bp_get_blog_latest_post_permalink()   X-Ref
Return the permalink of the latest post on the current blog in the loop.

return: string URL of the blog's latest post.
since: 1.7.0

bp_blog_latest_post_content()   X-Ref
Output the content of the latest post on the current blog in the loop.

since: 1.7.0

bp_get_blog_latest_post_content()   X-Ref
Return the content of the latest post on the current blog in the loop.

return: string Content of the blog's latest post.
since: 1.7.0

bp_blog_latest_post_featured_image( $size = 'thumbnail' )   X-Ref
Output the featured image of the latest post on the current blog in the loop.

param: string $size See {@link bp_get_blog_latest_post_featured_image()}.
since: 1.7.0

bp_get_blog_latest_post_featured_image( $size = 'thumbnail' )   X-Ref
Return the featured image of the latest post on the current blog in the loop.

param: string $size Image version to return. 'thumbnail', 'medium',
return: string URL of the image.
since: 1.7.0

bp_blog_latest_post_has_featured_image( $thumbnail = 'thumbnail' )   X-Ref
Does the latest blog post have a featured image?

param: string $thumbnail Image version to return. 'thumbnail', 'medium', 'large',
return: bool True if the latest blog post from the current blog has a
since: 1.7.0

bp_blog_hidden_fields()   X-Ref
Output hidden fields to help with form submissions in Sites directory.

This function detects whether 's', 'letter', or 'blogs_search' requests are
currently being made (as in a URL parameter), and creates corresponding
hidden fields.

bp_total_blog_count()   X-Ref
Output the total number of blogs on the site.


bp_get_total_blog_count()   X-Ref
Return the total number of blogs on the site.

return: int Total number of blogs.

bp_total_blog_count_for_user( $user_id = 0 )   X-Ref
Output the total number of blogs for a given user.

param: int $user_id ID of the user.

bp_get_total_blog_count_for_user( $user_id = 0 )   X-Ref
Return the total number of blogs for a given user.

param: int $user_id ID of the user.
return: int Total number of blogs for the user.

bp_blog_signup_enabled()   X-Ref
Checks whether blog creation is enabled.

Returns true when blog creation is enabled for logged-in users only, or
when it's enabled for new registrations.

return: bool True if blog registration is enabled.

bp_show_blog_signup_form($blogname = '', $blog_title = '', $errors = '')   X-Ref
Output the wrapper markup for the blog signup form.

param: string          $blogname   Optional. The default blog name (path or domain).
param: string          $blog_title Optional. The default blog title.
param: string|WP_Error $errors     Optional. The WP_Error object returned by a previous

bp_blogs_signup_blog( $blogname = '', $blog_title = '', $errors = '' )   X-Ref
Output the input fields for the blog creation form.

param: string          $blogname   Optional. The default blog name (path or domain).
param: string          $blog_title Optional. The default blog title.
param: string|WP_Error $errors     Optional. The WP_Error object returned by a previous

bp_blogs_validate_blog_signup()   X-Ref
Process a blog registration submission.

Passes submitted values to {@link wpmu_create_blog()}.

return: bool True on success, false on failure.

bp_blogs_validate_blog_form()   X-Ref
Validate a blog creation submission.

Essentially, a wrapper for {@link wpmu_validate_blog_signup()}.

return: array Contains the new site data and error messages.

bp_blogs_confirm_blog_signup( $domain, $path, $blog_title, $user_name, $user_email = '', $meta = '', $blog_id = null )   X-Ref
Display a message after successful blog registration.

param: string       $domain     The new blog's domain.
param: string       $path       The new blog's path.
param: string       $blog_title The new blog's title.
param: string       $user_name  The user name of the user who created the blog. Unused.
param: string       $user_email The email of the user who created the blog. Unused.
param: string|array $meta       Meta values associated with the new blog. Unused.
param: int|null     $blog_id    ID of the newly created blog.
since: 2.6.0 Introduced `$blog_id` parameter.

bp_create_blog_link()   X-Ref
Output a "Create a Site" link for users viewing their own profiles.

This function is not used by BuddyPress as of 1.2, but is kept here for older
themes that may still be using it.

bp_blogs_blog_tabs()   X-Ref
Output navigation tabs for a user Blogs page.

Currently unused by BuddyPress.

bp_directory_blogs_search_form()   X-Ref
Output the blog directory search form.


bp_blog_create_button()   X-Ref
Output the Create a Site button.

since: 2.0.0

bp_get_blog_create_button()   X-Ref
Get the Create a Site button.

return: false|string
since: 2.0.0

bp_blog_create_nav_item()   X-Ref
Output the Create a Site nav item.

since: 2.2.0

bp_get_blog_create_nav_item()   X-Ref
Get the Create a Site nav item.

return: string
since: 2.2.0

bp_blog_backcompat_create_nav_item()   X-Ref
Checks if a specific theme is still filtering the Blogs directory title
if so, transform the title button into a Blogs directory nav item.

return: string|null HTML Output
since: 2.2.0

bp_blogs_visit_blog_button( $args = '' )   X-Ref
Output button for visiting a blog in a loop.

param: array|string $args See {@link bp_get_blogs_visit_blog_button()}.

bp_get_blogs_visit_blog_button( $args = '' )   X-Ref
Return button for visiting a blog in a loop.

param: array|string $args {
return: string The HTML for the Visit button.

bp_blogs_profile_stats( $args = '' )   X-Ref
Display the number of blogs in user's profile.

param: array|string $args Before|after|user_id.
since: 2.0.0

bp_blogs_get_profile_stats( $args = '' )   X-Ref
Return the number of blogs in user's profile.

param: array|string $args Before|after|user_id.
return: string HTML for stats output.
since: 2.0.0



Generated: Tue Nov 19 01:01:36 2019 Cross-referenced by PHPXref 0.7.1