Description
Format the bw_plug output as a table with a number of columns- plugin name and short description
- link to plugin, link to plugin's home page, link to [bw]'s notes on the plugin
- other stuff: version, number times downloaded, last update date, tested up to WP x.x.xx
- $name
- ( mixed ) required –
- $link
- ( mixed ) required –
- $plugininfo
- ( mixed ) required –
- alink() – Create a link
- br() – Produce a break tag with optional text to follow
- bw_link_notes_page() – Create a link to the notes page.
- bw_link_plugin_download() – Create a link to the plugin’s download page
- etag() – Output an end tag
- stag() – Output an HTML opening tag
- strong() –
- td() – Output a table data field
Usage
bw_format_plug_table( $name, $link, $plugininfo );Parameters
Returns
voidSource
File name: oik-bob-bing-wide/shortcodes/oik-plug.phpLines:
1 to 49 of 49
function bw_format_plug_table( $name, $link, $plugininfo ) { stag( "tr"); if ( $plugininfo === FALSE ) { td( $name ); td( "No info available <!-- $link -->" ); td( " " ); } else { stag( "td", 'name' ); strong( $plugininfo->name ); br(); e( $plugininfo->short_description ); etag( "td" ); stag( "td", 'links' ); $download_page = bw_link_plugin_download( $name, $plugininfo ); if ( $download_page != $plugininfo->homepage ) { br(); alink( "home", $plugininfo->homepage, "home", "Link to plugin homepage" ); } br(); bw_link_notes_page( $name, $link ); etag( "td" ); stag( 'td', 'vtdlut'); sepan( 'version', $plugininfo->version ); br(); $downloaded = bw_get_property( $plugininfo, "Downloaded", null ); if ( is_numeric( $downloaded ) ) { sepan( 'downloaded', number_format_i18n( $downloaded, 0 ) ); br(); } else { sepan( 'downloaded', $downloaded ); br(); } $last_updated = bw_get_property( $plugininfo, "Last_updated", null ); if ( function_exists( 'wp_date') ) { $time = strtotime( $last_updated ) ; $format = get_option( 'date_format' ); $formatted_date = wp_date( $format, $time ); } else { $formatted_date = substr( $last_updated, 0, 10 ); } sepan( 'updated', $formatted_date ); br(); $tested = bw_get_property( $plugininfo, "Tested", null ); sepan( 'tested', $tested ); etag( 'td' ); } etag("tr"); }View on GitHub
Invoked by
Calls
1 to 8 of 8
Call hooks
API Letters:
