bp_get_blogs_visit_blog_button

Return button for visiting a blog in a loop.

Description

(string) bp_get_blogs_visit_blog_button( (string) $args = '' ); 

Returns (string)

The HTML for the Visit button.

Parameters (1)

0. $args — Optional. (string) => ''
The args.

Options

    ;        


    Usage

    1. if ( !function_exists( 'bp_get_blogs_visit_blog_button' ) ) { 
    2. require_once ABSPATH . PLUGINDIR . 'buddypress/bp-blogs/bp-blogs-template.php'; 
    3.  
    4. // The args. 
    5. $args = ''; 
    6.  
    7. // NOTICE! Understand what this does before running. 
    8. $result = bp_get_blogs_visit_blog_button($args); 
    9.  

    Defined (1)

    The function is defined in the following location(s).

    /bp-blogs/bp-blogs-template.php  
    1. function bp_get_blogs_visit_blog_button( $args = '' ) { 
    2. $defaults = array( 
    3. 'id' => 'visit_blog',  
    4. 'component' => 'blogs',  
    5. 'must_be_logged_in' => false,  
    6. 'block_self' => false,  
    7. 'wrapper_class' => 'blog-button visit',  
    8. 'link_href' => bp_get_blog_permalink(),  
    9. 'link_class' => 'blog-button visit',  
    10. 'link_text' => __( 'Visit Site', buddypress ),  
    11. ); 
    12.  
    13. $button = wp_parse_args( $args, $defaults ); 
    14.  
    15. /** 
    16. * Filters the button for visiting a blog in a loop. 
    17. * @since 1.2.10 
    18. * @param array $button Array of arguments to be used for the button to visit a blog. 
    19. */