';
echo _n( 'Add Image', 'Add Images', ( $multiple ? 2 : 1 ), 'beans' );
echo '';
echo '';
echo '
';
foreach ( $images as $id ) {
// Stop here if the id is false.
if ( !$id )
continue;
$class = '';
$img = wp_get_attachment_image_src( $id, 'thumbnail' );
$attributes = array_merge( array(
'class' => 'image-id',
'type' => 'hidden',
'name' => $multiple ? $field['name'] . '[]' : $field['name'], // Return single value if not multiple.
'value' => $id
), $field['attributes'] );
// Set placeholder.
if ( $id == 'placeholder' ) {
$class = 'bs-image-template';
$attributes = array_merge( $attributes, array( 'disabled' => 'disabled', 'value' => false ) );
}
echo '
';
echo '
';
echo '
 . ')
';
echo '
';
echo '
';
}
echo '
';
}