i have this code in functions.php:
//ADD SIZE TO MY IMAGE
add_image_size( ‘imoveis-thumb’, 200, 130, true); //(cropped)
//REGISTER FIELDS IN MY CPT
register_field_group(array (
‘id’ => ‘imovel_galeria-do-imovel’,
‘title’ => ‘Galeria do imovel’,
‘fields’ => array (
array (
‘key’ => ‘field_galeria’,
‘label’ => ‘galeria’,
‘name’ => ‘galeria’,
‘type’ => ‘gallery’,
‘required’ => 1,
‘preview_size’ => ‘imoveis-thumb’,
‘library’ => ‘uploadedTo’,
),
),
‘location’ => array (
array (
array (
‘param’ => ‘post_type’,
‘operator’ => ‘==’,
‘value’ => ‘imoveis’,
‘order_no’ => 0,
‘group_no’ => 0,
),
),
),
‘options’ => array (
‘position’ => ‘normal’,
‘layout’ => ‘default’,
‘hide_on_screen’ => array (
),
),
‘menu_order’ => 0,
));
but when i update any image in library the code:
get_field(‘galeria’)
not update the ‘imoveis-thumb’ url
why?