Making WordPress.org


Ignore:
Timestamp:
03/19/2015 10:37:51 PM (10 years ago)
Author:
coffee2code
Message:

Handbook plugin: Add 'tutorial' shortcode. Fixes #955.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/handbook/inc/callout-boxes.php

    r879 r1430  
    2727            'tip'     => __( 'Tip:',     'wporg' ),
    2828            'alert'   => __( 'Alert:',   'wporg' ),
     29            'tutorial' => __( 'Tutorial:', 'wporg' ),
    2930            'warning' => __( 'Warning:', 'wporg' )
    3031        );
     
    8485
    8586    /**
     87     * Output callback for the `[tutorial]` shortcode.
     88     *
     89     * @access public
     90     *
     91     * @param array  $atts    Shortcode attributes.
     92     * @param string $content Shortcode content.
     93     * @return string Shortcode output as HTML markup.
     94     */
     95    public function tutorial_shortcode( $atts, $content = '' ) {
     96        return $this->build_callout_output( $content, 'tutorial' );
     97    }
     98
     99    /**
    86100     * Output callback for the `[warning]` shortcode.
    87101     *
     
    133147
    134148$callouts = new WPorg_Handbook_Callout_Boxes();
    135 
Note: See TracChangeset for help on using the changeset viewer.