Try this one guys.It’s working for me.
function create_field( $field )
{
// vars
$o = array(
'class' => '',
'url' => '',
);
if( $field['value'] && is_numeric($field['value']) )
{
$url = wp_get_attachment_image_src($field['value'], $field['preview_size']);
if( $url !== false ) {
$o['class'] = 'active';
$o['url'] = $url[0];
}
}
“Edit this function as above. path is : core/fields/image.php “
Please Try this one guys.
function create_field( $field )
{
// vars
$o = array(
'class' => '',
'url' => '',
);
if( $field['value'] && is_numeric($field['value']) )
{
$url = wp_get_attachment_image_src($field['value'], $field['preview_size']);
if( $url !== false ) {
$o['class'] = 'active';
$o['url'] = $url[0];
}
}
“Edit this function as above. path is : core/fields/image.php “