You appear to be a bot. Output may be restricted
Description
Display the company logo with a link if requiredNotes: the attribute defaulting needs to be improved
Usage
$string = bw_logo( $atts );
Parameters
- $atts
- ( array ) optional – shortcode parameters
Returns
string HTML for the company logo imageSource
File name: oik/shortcodes/oik-logo.phpLines:
1 to 32 of 32
function bw_logo( $atts=null ) { $link = bw_array_get( $atts, 'link', null ); $text = bw_array_get( $atts, 'text', null ); $width = bw_array_get( $atts, 'width', null ); $height = bw_array_get( $atts, 'height', null ); $extras = null; //$upload_dir = wp_upload_dir(); //$baseurl = $upload_dir['baseurl']; $logo_image = bw_get_option( "logo-image" ); if ( $text ) { $company = $text; } else { $company = bw_get_option( "company" ); } $image_url = bw_get_logo_image_url( $logo_image ); sdiv( 'bw_logo'); if ( $image_url ) { if ( $width && $height ) { $extras = kv( "loading", "lazy"); } $image = retimage( "bw_logo", $image_url, $company, $width, $height, $extras ); if ( $link ) { $link = bw_logo_link( $link, $atts ); BW_::alink( "bw_logo", $link, $image, $company ); } else { e( $image ); } } ediv(); return bw_ret(); }View on GitHub View on Trac