bw_format_as_required() – Format the post as specified by the user

You appear to be a bot. Output may be restricted

Description

Format the post as specified by the user

The format= parameter is used to specify the fields to be displayed. Each field or metadata has a single digit code. The output is written to the internal buffer used by all shortcodes.

Usage

bw_format_as_required( $post, $atts );

Parameters

$post
( object ) required – the post to format
$atts
( array ) required – the attributes

Returns

void

Source

File name: oik/includes/bw_formatter.inc
Lines:

1 to 10 of 10
function bw_format_as_required( $post, $atts ) {
  $format = $atts['format'];
  $fs = str_split( $format );
  $in_block = bw_format_block_start( $post, $atts, false );
  foreach ( $fs as $f ) {
    $function = bw_field_function( $f );
    $function( $post, $atts, $f );
  }
  bw_format_block_end( $post, $atts, $in_block );
}
 

 View on Trac