| @@ -309,9 +309,9 @@ | ||
| 309 | 309 | */ |
| 310 | 310 | public function get_table_html( $headers, $rows, $table_id = 'results' ) { |
| 311 | 311 | ob_start(); |
| 312 | 312 | ?> |
| 313 | - <table cellspacing="0" width="100%" id="<?= $table_id ?>"> | |
| 313 | + <table cellspacing="0" width="100%" id="<?php echo esc_attr($table_id) ?>"> | |
| 314 | 314 | <thead> |
| 315 | 315 | <tr> |
| 316 | 316 | <?php |
| 317 | 317 | foreach ( $headers as $header ) { |
| @@ -317,9 +317,9 @@ | ||
| 317 | 317 | foreach ( $headers as $header ) { |
| 318 | 318 | if( empty( $header ) ){ |
| 319 | 319 | continue; |
| 320 | 320 | } |
| 321 | - echo '<th>' . $header . '</th>'; | |
| 321 | + echo '<th>' . esc_html($header) . '</th>'; | |
| 322 | 322 | } |
| 323 | 323 | ?> |
| 324 | 324 | </tr> |
| 325 | 325 | </thead> |
| @@ -332,9 +332,9 @@ | ||
| 332 | 332 | continue; |
| 333 | 333 | } |
| 334 | 334 | echo '<tr>'; |
| 335 | 335 | foreach ( $row as $r ) { |
| 336 | - echo '<td>' . $r . '</td>'; | |
| 336 | + echo '<td>' . esc_html($r) . '</td>'; | |
| 337 | 337 | } |
| 338 | 338 | echo '</tr>'; |
| 339 | 339 | } |
| 340 | 340 | ?> |
| @@ -459,8 +459,19 @@ | ||
| 459 | 459 | "right" => __("Right", "chart-builder"), |
| 460 | 460 | "center" => __("Center", "chart-builder") |
| 461 | 461 | ); |
| 462 | 462 | |
| 463 | + $border_styles = array( | |
| 464 | + "solid" => __("Solid", "chart-builder"), | |
| 465 | + "dashed" => __("Dashed", "chart-builder"), | |
| 466 | + "dotted" => __("Dotted", "chart-builder"), | |
| 467 | + "double" => __("Double", "chart-builder"), | |
| 468 | + "groove" => __("Groove", "chart-builder"), | |
| 469 | + "inset" => __("Inset", "chart-builder"), | |
| 470 | + "outset" => __("Outset", "chart-builder"), | |
| 471 | + "ridge" => __("Ridge", "chart-builder") | |
| 472 | + ); | |
| 473 | + | |
| 463 | 474 | $animation_easing_options = array( |
| 464 | 475 | "linear" => __("Linear", "chart-builder"), |
| 465 | 476 | "in" => __("Ease in", "chart-builder"), |
| 466 | 477 | "out" => __("Ease out", "chart-builder"), |
| @@ -576,8 +587,27 @@ | ||
| 576 | 587 | |
| 577 | 588 | // Border color |
| 578 | 589 | $settings['border_color'] = isset( $settings['border_color'] ) && $settings['border_color'] != '' ? esc_attr( $settings['border_color'] ) : '#666666'; |
| 579 | 590 | |
| 591 | + // Border style | |
| 592 | + $settings['border_style'] = isset( $settings['border_style'] ) && $settings['border_style'] != '' ? esc_attr( $settings['border_style'] ) : 'solid'; | |
| 593 | + | |
| 594 | + // Border width with title | |
| 595 | + $settings['border_width_with_title'] = isset( $settings['border_width_with_title'] ) && $settings['border_width_with_title'] != '' ? esc_attr( $settings['border_width_with_title'] ) : '0'; | |
| 596 | + | |
| 597 | + // Border radius with title | |
| 598 | + $settings['border_radius_with_title'] = isset( $settings['border_radius_with_title'] ) && $settings['border_radius_with_title'] != '' ? esc_attr( $settings['border_radius_with_title'] ) : '0'; | |
| 599 | + | |
| 600 | + // Border color with title | |
| 601 | + $settings['border_color_with_title'] = isset( $settings['border_color_with_title'] ) && $settings['border_color_with_title'] != '' ? esc_attr( $settings['border_color_with_title'] ) : '#000000'; | |
| 602 | + | |
| 603 | + // Border style with title | |
| 604 | + $settings['border_style_with_title'] = isset( $settings['border_style_with_title'] ) && $settings['border_style_with_title'] != '' ? esc_attr( $settings['border_style_with_title'] ) : 'solid'; | |
| 605 | + $settings['border_styles'] = $border_styles; | |
| 606 | + | |
| 607 | + // Padding outer | |
| 608 | + $settings['padding_outer'] = isset( $settings['padding_outer'] ) && $settings['padding_outer'] != '' ? esc_attr( $settings['padding_outer'] ) : '0'; | |
| 609 | + | |
| 580 | 610 | // Box shadow color |
| 581 | 611 | $settings['box_shadow_color'] = isset( $settings['box_shadow_color'] ) && $settings['box_shadow_color'] != '' ? esc_attr( $settings['box_shadow_color'] ) : $settings['border_color']; |
| 582 | 612 | |
| 583 | 613 | // Chart Area background color |
| @@ -1010,9 +1040,27 @@ | ||
| 1010 | 1040 | $settings['border_radius'] = isset( $settings['border_radius'] ) && $settings['border_radius'] != '' ? esc_attr( $settings['border_radius'] ) : '0'; |
| 1011 | 1041 | |
| 1012 | 1042 | // Border color |
| 1013 | 1043 | $settings['border_color'] = isset( $settings['border_color'] ) && $settings['border_color'] != '' ? esc_attr( $settings['border_color'] ) : '#666666'; |
| 1044 | + | |
| 1045 | + // Border style | |
| 1046 | + $settings['border_style'] = isset( $settings['border_style'] ) && $settings['border_style'] != '' ? esc_attr( $settings['border_style'] ) : 'solid'; | |
| 1047 | + | |
| 1048 | + // Border width with title | |
| 1049 | + $settings['border_width_with_title'] = isset( $settings['border_width_with_title'] ) && $settings['border_width_with_title'] != '' ? esc_attr( $settings['border_width_with_title'] ) : '0'; | |
| 1014 | 1050 | |
| 1051 | + // Border radius with title | |
| 1052 | + $settings['border_radius_with_title'] = isset( $settings['border_radius_with_title'] ) && $settings['border_radius_with_title'] != '' ? esc_attr( $settings['border_radius_with_title'] ) : '0'; | |
| 1053 | + | |
| 1054 | + // Border color with title | |
| 1055 | + $settings['border_color_with_title'] = isset( $settings['border_color_with_title'] ) && $settings['border_color_with_title'] != '' ? esc_attr( $settings['border_color_with_title'] ) : '#000000'; | |
| 1056 | + | |
| 1057 | + // Border style with title | |
| 1058 | + $settings['border_style_with_title'] = isset( $settings['border_style_with_title'] ) && $settings['border_style_with_title'] != '' ? esc_attr( $settings['border_style_with_title'] ) : 'solid'; | |
| 1059 | + | |
| 1060 | + // Padding outer | |
| 1061 | + $settings['padding_outer'] = isset( $settings['padding_outer'] ) && $settings['padding_outer'] != '' ? esc_attr( $settings['padding_outer'] ) : '0'; | |
| 1062 | + | |
| 1015 | 1063 | // Box shadow color |
| 1016 | 1064 | $settings['box_shadow_color'] = isset( $settings['box_shadow_color'] ) && $settings['box_shadow_color'] != '' ? esc_attr( $settings['box_shadow_color'] ) : $settings['border_color']; |
| 1017 | 1065 | |
| 1018 | 1066 | // Chart Area background color |
| @@ -1355,8 +1403,19 @@ | ||
| 1355 | 1403 | "underline" => __("Underline", "chart-builder"), |
| 1356 | 1404 | "line-through" => __("Line through", "chart-builder"), |
| 1357 | 1405 | "none" => __("None", "chart-builder"), |
| 1358 | 1406 | ); |
| 1407 | + | |
| 1408 | + $border_styles = array( | |
| 1409 | + "solid" => __("Solid", "chart-builder"), | |
| 1410 | + "dashed" => __("Dashed", "chart-builder"), | |
| 1411 | + "dotted" => __("Dotted", "chart-builder"), | |
| 1412 | + "double" => __("Double", "chart-builder"), | |
| 1413 | + "groove" => __("Groove", "chart-builder"), | |
| 1414 | + "inset" => __("Inset", "chart-builder"), | |
| 1415 | + "outset" => __("Outset", "chart-builder"), | |
| 1416 | + "ridge" => __("Ridge", "chart-builder") | |
| 1417 | + ); | |
| 1359 | 1418 | |
| 1360 | 1419 | // Title color |
| 1361 | 1420 | $settings['title_color'] = isset( $settings['title_color'] ) && $settings['title_color'] != '' ? esc_attr( $settings['title_color'] ) : '#000000'; |
| 1362 | 1421 | |
| @@ -1431,8 +1490,25 @@ | ||
| 1431 | 1490 | |
| 1432 | 1491 | // description text decoration |
| 1433 | 1492 | $settings['description_text_decoration'] = isset( $settings['description_text_decoration'] ) && $settings['description_text_decoration'] != '' ? esc_attr( $settings['description_text_decoration'] ) : 'none'; |
| 1434 | 1493 | |
| 1494 | + // Box shadow | |
| 1495 | + $settings['box_shadow'] = isset( $settings['box_shadow'] ) && $settings['box_shadow'] != '' ? esc_attr( $settings['box_shadow'] ) : 'off'; | |
| 1496 | + $settings['box_shadow'] = isset( $settings['box_shadow'] ) && $settings['box_shadow'] == 'on' ? 'checked' : ''; | |
| 1497 | + | |
| 1498 | + // Border width | |
| 1499 | + $settings['border_width'] = isset( $settings['border_width'] ) && $settings['border_width'] != '' ? esc_attr( $settings['border_width'] ) : '0'; | |
| 1500 | + | |
| 1501 | + // Border radius | |
| 1502 | + $settings['border_radius'] = isset( $settings['border_radius'] ) && $settings['border_radius'] != '' ? esc_attr( $settings['border_radius'] ) : '0'; | |
| 1503 | + | |
| 1504 | + // Border color | |
| 1505 | + $settings['border_color'] = isset( $settings['border_color'] ) && $settings['border_color'] != '' ? esc_attr( $settings['border_color'] ) : '#000000'; | |
| 1506 | + | |
| 1507 | + // Border style | |
| 1508 | + $settings['border_style'] = isset( $settings['border_style'] ) && $settings['border_style'] != '' ? esc_attr( $settings['border_style'] ) : 'solid'; | |
| 1509 | + $settings['border_styles'] = $border_styles; | |
| 1510 | + | |
| 1435 | 1511 | // outer_radius |
| 1436 | 1512 | $settings['outer_radius'] = isset( $settings['outer_radius'] ) && $settings['outer_radius'] != '' ? esc_attr( absint($settings['outer_radius']) ) : 100; |
| 1437 | 1513 | |
| 1438 | 1514 | // slice_spacing |
| @@ -1548,8 +1624,24 @@ | ||
| 1548 | 1624 | |
| 1549 | 1625 | // description text decoration |
| 1550 | 1626 | $settings['description_text_decoration'] = isset( $settings['description_text_decoration'] ) && $settings['description_text_decoration'] != '' ? esc_attr( $settings['description_text_decoration'] ) : 'none'; |
| 1551 | 1627 | |
| 1628 | + // Box shadow | |
| 1629 | + $settings['box_shadow'] = isset( $settings['box_shadow'] ) && $settings['box_shadow'] != '' ? esc_attr( $settings['box_shadow'] ) : 'off'; | |
| 1630 | + $settings['box_shadow'] = isset( $settings['box_shadow'] ) && $settings['box_shadow'] == 'on' ? 'checked' : ''; | |
| 1631 | + | |
| 1632 | + // Border width | |
| 1633 | + $settings['border_width'] = isset( $settings['border_width'] ) && $settings['border_width'] != '' ? esc_attr( $settings['border_width'] ) : '0'; | |
| 1634 | + | |
| 1635 | + // Border radius | |
| 1636 | + $settings['border_radius'] = isset( $settings['border_radius'] ) && $settings['border_radius'] != '' ? esc_attr( $settings['border_radius'] ) : '0'; | |
| 1637 | + | |
| 1638 | + // Border color | |
| 1639 | + $settings['border_color'] = isset( $settings['border_color'] ) && $settings['border_color'] != '' ? esc_attr( $settings['border_color'] ) : '#000000'; | |
| 1640 | + | |
| 1641 | + // Border style | |
| 1642 | + $settings['border_style'] = isset( $settings['border_style'] ) && $settings['border_style'] != '' ? esc_attr( $settings['border_style'] ) : 'solid'; | |
| 1643 | + | |
| 1552 | 1644 | // outer_radius |
| 1553 | 1645 | $settings['outer_radius'] = isset( $settings['outer_radius'] ) && $settings['outer_radius'] != '' ? esc_attr( absint($settings['outer_radius']) ) : 100; |
| 1554 | 1646 | |
| 1555 | 1647 | // slice_spacing |