Passing the number via php
-
Hi,
I made up a SQL query to get the data I want.
But it displays the Shortcode and not the chart.CAN YOU HELP ME OUT WITH IT?
// EXAMPLE CHART
global $wpdb;
$num_registros = $wpdb->get_results( ‘SELECT item_id FROM wp_frm_item_metas WHERE field_id = 126’ );echo ‘<div>[wp_charts title=”barchart” type=”bar” align=”alignleft” margin=”5px 20px” datasets=”‘;
foreach ( $num_registros as $num_registro)
{
echo $num_registro->item_id . ‘,’; ;
}echo ‘”]</div>’;
The result on my page is [wp_charts title=”barchart” type=”bar” align=”alignleft” margin=”5px 20px” datasets=”98,94,90,89,88,”], But I can’t get the chart to show!
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘Passing the number via php’ is closed to new replies.