PluginProbe
Chartify – WordPress Chart Plugin / 3.2.7
Chartify – WordPress Chart Plugin v3.2.7
3.8.0 3.7.9 3.7.8 3.7.7 3.7.6 3.7.5 trunk 1.0.0 3.0.0 3.0.1 3.0.2 3.0.3 3.0.4 3.0.5 3.0.6 3.0.7 3.0.8 3.0.9 3.1.0 3.1.1 3.1.2 3.1.3 3.1.4 3.1.5 3.1.6 All 83 releases
← All changes | includes/class-chart-builder-db-query.php +4 -4 3.0.13.2.7 View file →
@@ -161,9 +161,9 @@
161 161 }
162 162
163 163 // only select queries allowed.
164 164 if ( preg_match( '/^\s*(insert|delete|update|replace|create|alter|drop|truncate)\s/i', $this->_query ) ) {
165 - $this->_error = __( 'Only SELECT queries are allowed', CHART_BUILDER_NAME );
165 + $this->_error = __( 'Only SELECT queries are allowed', 'chart-builder' );
166 166 return false;
167 167 }
168 168
169 169 $validate_query = str_replace( "\n", ' ', $this->_query );
@@ -282,9 +282,9 @@
282 282 <thead>
283 283 <tr>
284 284 <?php
285 285 foreach ( $headers as $header ) {
286 - echo '<th>' . $header['label'] . '</th>';
286 + echo '<th>' . esc_html($header['label']) . '</th>';
287 287 }
288 288 ?>
289 289 </tr>
290 290 </thead>
@@ -294,9 +294,9 @@
294 294 <?php
295 295 foreach ( $results as $result ) {
296 296 echo '<tr>';
297 297 foreach ( $result as $r ) {
298 - echo '<td>' . $r . '</td>';
298 + echo '<td>' . esc_html($r) . '</td>';
299 299 }
300 300 echo '</tr>';
301 301 }
302 302 ?>
@@ -532,9 +532,9 @@
532 532 // let's randomly pick 5 data points instead of cycling through the entire data set.
533 533 if ( count( $data ) > 5 ) {
534 534 $random = array();
535 535 for ( $x = 0; $x < 5; $x++ ) {
536 - $random[] = $data[ rand( 0, count( $data ) - 1 ) ];
536 + $random[] = $data[ wp_rand( 0, count( $data ) - 1 ) ];
537 537 }
538 538 }
539 539
540 540 foreach ( $types as $type ) {