Settings', 'all-in-one-minifier')), array('tab2', 'all-in-one-minifier-report', 'fa-chart-line', __(' Page Speed Report', 'all-in-one-minifier')), array('tab3', 'all-in-one-minifier-about', 'fa-info-circle', __(' About', 'all-in-one-minifier')), array('tab4', 'all-in-one-minifier-donate', 'fa-info-circle', __(' Say Thanks', 'all-in-one-minifier')) ); $menu = null; foreach ($list as $item => $value) { $menu .= '
' . $value[3] . '
'; } echo wp_kses_post($menu); } /** * Register the stylesheet file(s) for the dashboard area */ public function enqueue_backend_standalone() { wp_register_style($this->plugin_name . '-standalone', plugin_dir_url(__FILE__) . 'assets/styles/standalone.css', array(), $this->version, 'all'); wp_enqueue_style($this->plugin_name . '-standalone'); } /** * Update `Options` on form submit */ public function return_update_options() { if ((isset($_POST['all-in-one-minifier-update-option'])) && ($_POST['all-in-one-minifier-update-option'] == 'true') && check_admin_referer('pwm-referer-form', 'pwm-referer-option') ) { $opts = array('start_minify' => 'off', 'admin' => 'off', 'loadtime' => 'off'); if (isset($_POST['_all-in-one_minifier']['start_minify'])) { $opts['start_minify'] = 'on'; } // if(isset($_POST['_all-in-one_minifier']['admin'])) // { // $opts['admin'] = 'on'; // } // if(isset($_POST['_all-in-one_minifier']['loadtime'])) // { // $opts['loadtime'] = 'on'; // } update_option('_all-in-one_minifier', $opts); $this->notice = array('success', __('Your settings have been successfully updated.', 'all-in-one-minifier')); // header('location:' . admin_url('admin.php?page=all-in-one-minifier-admin') . '&status=updated'); // die(); } } /** * Return the `Options` page */ public function return_options_page() { $this->_getJSReady(); $opts = get_option('_all-in-one_minifier'); // if ((isset($_GET['status'])) && ($_GET['status'] == 'updated')) { // $this->notice = array('success', __('Your settings have been successfully updated.', AOMIN_PLUGIN_IDENTIFIER)); // } $allPostTypes = array(); $args = array( 'public' => true, ); $post_types = get_post_types($args, 'objects'); foreach ($post_types as $post_type_obj) : if ($post_type_obj->name != 'attachment') { array_push($allPostTypes, $post_type_obj->name); } endforeach; $wc_query = new WP_Query(array( 'post_type' => $allPostTypes, 'post_status' => 'publish', 'posts_per_page' => -1 )); $allPostData = array(); if ($wc_query->have_posts()) { while ($wc_query->have_posts()) { $wc_query->the_post(); $post_id = get_the_ID(); $allPostData[] = ['post' => get_permalink($post_id)]; } } $disablePluginOption = ''; $frontpage_id = get_option('page_on_front'); if (!isset($opts['start_minify']) || ($opts['start_minify']) == 'off') { $disablePluginOption = 'alone-disabled-options'; } if ($frontpage_id == '' || $frontpage_id == '0') { $disablePluginOption = 'alone-disabled-options'; } ?>
return_plugin_header()); ?>
return_tabs_menu('tab1')); ?>
notice) && !empty($this->notice)) { ?>
× notice[1], AOMIN_PLUGIN_IDENTIFIER); ?>
×
×



0) { ?> href="javascript:_runCache()" > Generate Cache

for urls prefix . 'alone_minifier_analysis'; $pageposts = $wpdb->get_results("SELECT datetime FROM $table_name ORDER BY id DESC LIMIT 1"); if (count($pageposts) > 0) { ?> last cache on datetime))); ?>
' . esc_attr(AOMIN_PLUGIN_FULLNAME) . ''; return $html; } /** * Return the `About` page */ public function return_about_page() { ?>
= 1073741824) { $bytes = number_format($bytes / 1073741824, 2) . ' GB'; } elseif ($bytes >= 1048576) { $bytes = number_format($bytes / 1048576, 2) . ' MB'; } elseif ($bytes >= 1024) { $bytes = number_format($bytes / 1024, 2) . ' KB'; } elseif ($bytes > 1) { $bytes = $bytes . ' bytes'; } elseif ($bytes == 1) { $bytes = $bytes . ' byte'; } else { $bytes = '0 bytes'; } return $bytes; } public function return_generate_loadTime_report() { $this->_getJSReady(); $opts = get_option('_all-in-one_minifier'); $disablePluginOption = ''; $frontpage_id = get_option('page_on_front'); if (!isset($opts['start_minify']) || ($opts['start_minify']) == 'off') { $disablePluginOption = 'alone-disabled-options'; } if ($frontpage_id == '' || $frontpage_id == '0') { $disablePluginOption = 'alone-disabled-options'; } ?>
return_plugin_header()); ?>
return_tabs_menu('tab2')); ?> true, ); $post_types = get_post_types($args, 'objects'); foreach ($post_types as $post_type_obj) : if ($post_type_obj->name != 'attachment') { array_push($allPostTypes, $post_type_obj->name); } endforeach; } else { array_push($allPostTypes, $_GET['filter-post-type']); } $paged = @$_GET['paged']; set_query_var('paged', $paged); $paged = (get_query_var('paged')) ? get_query_var('paged') : 1; $wpposts = new WP_Query( array( 'post_type' => $allPostTypes, 'posts_per_page' => 10, 'paged' => $paged, 'post_status' => 'publish', 'orderby' => 'title', 'order' => 'ASC' ) ); if ($frontpage_id == '' || $frontpage_id == '0') { ?>
generatePagination($wpposts); ?> have_posts()) : $wpposts->the_post(); $postID = get_the_ID(); $post_title = get_the_title(); $current_queried_post_type = get_post_type($postID); $post_slug = All_In_One_Minifier_Core::parseURL(get_permalink()); $docBeforeTimePrint = ''; $docAfterTimePrint = ''; $af_docBeforeTime = ''; $af_docAfterTime = ''; if (file_exists(AOMIN_PLUGIN_ABS_CACHE_PATH . $post_slug . '.html')) { global $wpdb; $table_name = $wpdb->prefix . 'alone_minifier_analysis'; $pageposts_1 = $wpdb->get_results("SELECT postID, docBeforeTime, docAfterTime, minifyStatus, datetime FROM $table_name WHERE postID = $postID ORDER BY minifyStatus"); foreach ($pageposts_1 as $value_1) { $docBeforeTime = $value_1->docBeforeTime; $docAfterTime = $value_1->docAfterTime; $datetime = $value_1->datetime; $af_docBeforeTime = $docBeforeTime; $af_docAfterTime = $docAfterTime; $docBeforeTimePrint .= 'Before : ' . esc_attr($this->AIOMformatSizeUnits($docBeforeTime)) . ''; $docAfterTimePrint .= 'After : ' . esc_attr($this->AIOMformatSizeUnits($docAfterTime)) . ''; } } $minifiedPerComp = ''; $minifiedPerPrint = ''; if ($af_docAfterTime > 0 && $af_docBeforeTime > 0) { $minifiedPerComp = ($af_docAfterTime / $af_docBeforeTime) * 100; $minifiedPerComp = $minifiedPerComp - 100; $minifiedPerComp = abs($minifiedPerComp); $minifiedPerCompClass = 'color_red'; if ($af_docBeforeTime > $af_docAfterTime) { $minifiedPerCompClass = 'color_green'; } $minifiedPerPrint .= '' . number_format($minifiedPerComp, 2) . ' %'; } ?> have_posts()) { ?>
Content Page Before Optimization Page After Optimization Minified % Date
href="javascript:_buildCache('', -1)" class="row-title"> —
Last cache on
Build cache for this
href="javascript:_buildCache('', -1)" class="row-title">Click here
No records found.
Page Page Ready Time Page Completely Loaded Minified % Date
generatePagination($wpposts); ?>
Post Type
found_posts); ?> items
str_replace( $big, '%#%', get_pagenum_link( $big ) ), 'base' => $pageUrl, 'format' => '?paged=%#%', 'current' => max(1, get_query_var('paged')), 'total' => $wpposts->max_num_pages ))); ?>
return_plugin_header()); ?>
return_tabs_menu('tab4')); ?>

Scan below code



Mr Mahesh Mohan Thorat

UPI - maheshmthorat@oksbi

_getJSReady(); } public function call_action_generate_loadTime_report() { if (get_the_ID() > 0) { ?>

Please wait while we generating report for this page.

This will take less than a minute.
Note - Page will reload several times to generate report

Generating without web optimizations
Generating with web optimizations
Cancel Report
prefix . 'alone_minifier_analysis'; $pageposts_1 = $wpdb->get_results("SELECT postID, docBeforeTime, docAfterTime, minifyStatus, datetime FROM $table_name WHERE postID = $postID ORDER BY minifyStatus"); foreach ($pageposts_1 as $value_1) { $docBeforeTime = $value_1->docBeforeTime; $docAfterTime = $value_1->docAfterTime; $minifyStatus = $value_1->minifyStatus; $datetime = $value_1->datetime; $docBeforeTimePrint = ''; if ($minifyStatus == 0) { $bef_docBeforeTime = $docBeforeTime; $bef_docAfterTime = $docAfterTime; $docBeforeTimePrint .= 'Before : ' . $docBeforeTime . ' Sec
'; $docAfterTime .= 'Before : ' . $docAfterTime . ' Sec
'; } if ($minifyStatus == 1) { $af_docBeforeTime = $docBeforeTime; $af_docAfterTime = $docAfterTime; $docBeforeTimePrint .= 'After : ' . $docBeforeTime . ' Sec'; $docAfterTime .= 'After : ' . $docAfterTime . ' Sec'; } } $minifiedPerReady = ''; $minifiedPerComp = ''; $minifiedPerPrint = ''; if ($bef_docBeforeTime != '' && $bef_docAfterTime != '' && $af_docBeforeTime != '' && $af_docAfterTime != '') { $minifiedPerReady = ($bef_docBeforeTime / $af_docBeforeTime) * 100; $minifiedPerComp = ($bef_docAfterTime / $af_docAfterTime) * 100; $minifiedPerReadyClass = 'color_red'; $minifiedPerCompClass = 'color_red'; if ($bef_docBeforeTime > $af_docBeforeTime) { $minifiedPerReadyClass = 'color_green'; } if ($bef_docAfterTime > $af_docAfterTime) { $minifiedPerCompClass = 'color_green'; } $minifiedPerPrint = 'Page Ready : ' . number_format($minifiedPerReady, 2) . ' %'; $minifiedPerPrint .= '
Page Complete : ' . number_format($minifiedPerComp, 2) . ' %'; } $backBtnLink = admin_url('admin.php') . '?page=all-in-one-minifier-report'; ?>

Page Speed Report

Page Ready Time
Page Completely Loaded
Minified %
Close Report Back to All Report Re-Scan Page
" . __('Settings') . '', "Say Thanks"]; $links = array_merge( $settings_link, $links ); return $links; } public function my_custom_admin_bar_link($wp_admin_bar) { if (!is_admin()) { $opts = get_option('_all-in-one_minifier'); if (isset($opts['start_minify']) && $opts['start_minify'] == 'on') { $wp_admin_bar->add_menu(array( 'id' => AOMIN_PLUGIN_IDENTIFIER . '-shortcut', 'title' => ' Clear Cache', 'href' => '#', 'meta' => array( 'onclick' => '_buildCache("' . get_permalink() . '", -1); return false;', ), )); } } } }