Thanks for your quick response.
This is the code in my functions.php:
add_action( 'admin_init', 'rw_register_meta_box' );
function rw_register_meta_box()
{
// Check if plugin is activated or included in theme
if ( !class_exists( 'RW_Meta_Box' ) )
return;
$prefix = 'rw_';
$meta_box = array(
'id' => 'ministrylogo',
'title' => 'Personal Information',
'pages' => array( 'ministry_post'),
'context' => 'normal',
'priority' => 'high',
'fields' => array(
array(
'name' => 'Ministry Logos',
'type' => 'thickbox_image',
),
)
);
new RW_Meta_Box( $meta_box );
}
I am trying to get image using the code below in my index.php:
$images = rwmb_meta( 'ministrylogo', 'type=image' );
foreach ( $images as $image )
{
echo "<a href='{$image['full_url']}' title='{$image['title']}' rel='thickbox'><img src='{$image['url']}' width='{$image['width']}' height='{$image['height']}' alt='{$image['alt']}' /></a>";
}
I also tried replacing the field name (ministrylogo) with “rw_ministrylogo” but still does not work.
I really don’t know whats happening unless i am not doing the right thing.