Reply To: Mashup Popup template

Home Forums MapPress Support Mashup Popup template Reply To: Mashup Popup template

#18313
Chris
Keymaster

Hi,

The templates are editable via the MapPress settings screen.  They’re saved in your theme directory, and the originals are in the /templates directory of the plugin.  There’s general information about this in the MapPress documentation.

I think you are asking to display a field only if non-empty.  For that, you would need some javascript in the template.  You can do a simple if statement by using three braces:

{{{ (poi.props.annonce_surface) ? poi.props.annonce_surface : 'empty'}}}

Or, make a conditional block using ‘<#’ and ‘#>’ around the JavaScript parts:

<# if (poi.props.annonce_surafce) { #>
<i class=””fal” aria-hidden=””true””></i> {{poi.props.annonce_surface}} m²
<# } #>