Shortcode double quote issue in php
-
Hi,
I’m having an issue when trying to work with the shortcode directly in PHP. Here is the code I use :
<?php echo do_shortcode(‘[gfchartsreports gf_form_id=”1″ include=”42″ height=”300px” type=”horizontalBar” maxentries=”10000″ chart_js_options=”title: {display: false}” custom_search_criteria=”{“date_start”:”22 April 1980″,”date_end”:”12 Jun 2018″}”]’); ?>The chart works but the date range doesn’t. It works fine if I add the shortcode directly to wordpress, but the culprit seems to come from those double quotes in the custom_search_criteria option. Do you have a solution for that?
Regards,
Pierre
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Shortcode double quote issue in php’ is closed to new replies.