Perhaps a basic question, but can php code be used in editing the CartoDB infowindow HTML? We want to show or hide a category depending on the value.
1 Answer 1
Yes, you can do it. Just render the HTML you need in the view and "inject" that code in the visualization infowindow template. For example:
... layer.infowindow.set('template', document.getElementById('infowindow_template')); ...