a href='hidden link field=\'place\' output=\'raw\'][/types]' title='Apri google maps'>Apri google maps</a
is the snippet of code. I put out the < and > to make it readable. As you can see it doesn't work also escaping
OK I've found a workaround... writing it here for the sake of future users:
Create a custom shortcode and put in functions.php.
function generate_google_maps_link($atts) {
// Estrai i parametri dello shortcode, se necessario
$atts = shortcode_atts(
array(
'field' => 'place', // Campo di default
),
$atts,
'google_maps_link'
);
// Recupera il valore del campo 'place' usando Toolset Types API
if (function_exists('types_render_field')) {
$place = types_render_field($atts['field'], array('output' => 'raw'));
} else {
$place = '';
}
// Controlla se il campo è vuoto
if (empty($place)) {
return '<p>Campo non disponibile</p>';
}