PluginProbe
Visualizer – Tables & Charts Manager with Built-in AI Generator / 3.11.5
Visualizer – Tables & Charts Manager with Built-in AI Generator v3.11.5
4.0.8 4.0.7 4.0.6 4.0.5 4.0.4 4.0.3 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.10.0 3.10.1 3.10.10 3.10.11 3.10.12 3.10.13 3.10.14 3.10.15 3.10.2 3.10.3 All 149 releases
← All changes | classes/Visualizer/Module.php +20 -4 3.10.03.11.5 View file →
@@ -137,9 +137,9 @@
137 137 * @uses add_filter() To register filter hook.
138 138 *
139 139 * @access protected
140 140 * @param string $tag The name of the filter to hook the $method to.
141 - * @param type $method The name of the method to be called when the filter is applied.
141 + * @param string $method The name of the method to be called when the filter is applied.
142 142 * @param int $priority optional. Used to specify the order in which the functions associated with a particular action are executed (default: 10). Lower numbers correspond with earlier execution, and functions with the same priority are executed in the order in which they were added to the action.
143 143 * @param int $accepted_args optional. The number of arguments the function accept (default 1).
144 144 * @return Visualizer_Module
145 145 */
@@ -271,8 +271,11 @@
271 271 $bom = chr( 0xEF ) . chr( 0xBB ) . chr( 0xBF );
272 272 // phpcs:ignore WordPress.PHP.NoSilencedErrors.Discouraged
273 273 $fp = function_exists( 'tmpfile' ) ? @tmpfile() : null;
274 274 if ( null === $fp ) {
275 + if ( ! function_exists( 'wp_tempnam' ) ) {
276 + require_once ABSPATH . 'wp-admin/includes/file.php';
277 + }
275 278 $fp = fopen( wp_tempnam(), 'w+' );
276 279 }
277 280 if ( ! apply_filters( 'vizualizer_export_include_series_type', true ) ) {
278 281 unset( $rows[1] );
@@ -519,8 +522,12 @@
519 522
520 523 require_once( ABSPATH . 'wp-admin/includes/file.php' );
521 524 WP_Filesystem();
522 525 global $wp_filesystem;
526 + if ( ! is_a( $wp_filesystem, 'WP_Filesystem_Base' ) ) {
527 + $creds = request_filesystem_credentials( site_url() );
528 + wp_filesystem( $creds );
529 + }
523 530
524 531 $multisite_arg = '/';
525 532 if ( is_multisite() && ! is_main_site() ) {
526 533 $multisite_arg = '/sites/' . get_current_blog_id() . '/';
@@ -627,9 +634,9 @@
627 634 $settings['cssClassNames'] = $classes;
628 635 }
629 636
630 637 $img_path = VISUALIZER_ABSURL . 'images';
631 - $css .= ".locker,.locker-loader{position:absolute;top:0;left:0;width:100%;height:100%}.locker{z-index:1000;opacity:.8;background-color:#fff;-ms-filter:\"progid:DXImageTransform.Microsoft.Alpha(Opacity=80)\";filter:alpha(opacity=80)}.locker-loader{z-index:1001;background:url($img_path/ajax-loader.gif) no-repeat center center}.dt-button{display:none!important}.visualizer-front-container.visualizer-lazy-render{content-visibility: auto;}.google-visualization-controls-categoryfilter label.google-visualization-controls-label {vertical-align: middle;}.google-visualization-controls-categoryfilter li.goog-inline-block {margin: 0 0.2em;}.google-visualization-controls-categoryfilter li {padding: 0 0.2em;}";
638 + $css .= ".locker,.locker-loader{position:absolute;top:0;left:0;width:100%;height:100%}.locker{z-index:1000;opacity:.8;background-color:#fff;-ms-filter:\"progid:DXImageTransform.Microsoft.Alpha(Opacity=80)\";filter:alpha(opacity=80)}.locker-loader{z-index:1001;background:url($img_path/ajax-loader.gif) no-repeat center center}.dt-button{display:none!important}.visualizer-front-container.visualizer-lazy-render{content-visibility: auto;}.google-visualization-controls-categoryfilter label.google-visualization-controls-label {vertical-align: middle;}.google-visualization-controls-categoryfilter li.goog-inline-block {margin: 0 0.2em;}.google-visualization-controls-categoryfilter li {padding: 0 0.2em;}.visualizer-front-container .dataTables_scrollHeadInner{margin: 0 auto;}";
632 639 $css .= '</style>';
633 640
634 641 $arguments = array( $css, $settings );
635 642 apply_filters_ref_array( 'visualizer_inline_css', array( &$arguments ) );
@@ -730,13 +737,22 @@
730 737 /**
731 738 * Gets the features for the provided license type.
732 739 */
733 740 public static final function get_features_for_license( $plan ) {
741 + $is_new_personal = apply_filters( 'visualizer_is_new_personal', false );
734 742 switch ( $plan ) {
735 743 case 1:
736 - return array( 'import-wp', 'db-query', 'import-wc-report' );
744 + $features = array( 'import-wp', 'import-wc-report', 'import-file', 'import-url' );
745 + if ( ! $is_new_personal ) {
746 + $features[] = 'db-query';
747 + }
748 + return $features;
737 749 case 2:
738 - return array( 'schedule-chart', 'chart-permissions' );
750 + $features = array( 'schedule-chart', 'chart-permissions', 'import-chart', 'data-filter-configuration', 'frontend-actions' );
751 + if ( $is_new_personal ) {
752 + $features[] = 'db-query';
753 + }
754 + return $features;
739 755 }
740 756 }
741 757
742 758 /**