Changeset 2927143
- Timestamp:
- 06/16/2023 03:43:35 PM (3 years ago)
- Location:
- flywp
- Files:
-
- 5 added
- 2 deleted
- 44 edited
- 1 copied
-
assets/screenshot-1.png (added)
-
tags/0.3.2 (copied) (copied from flywp/trunk)
-
tags/0.3.2/assets/css/app.css (modified) (13 diffs)
-
tags/0.3.2/assets/css/app.min.css (modified) (1 diff)
-
tags/0.3.2/assets/images (added)
-
tags/0.3.2/assets/images/flywp-logo.svg (added)
-
tags/0.3.2/assets/js/admin.js (modified) (1 diff)
-
tags/0.3.2/assets/js/admin.min.js (modified) (1 diff)
-
tags/0.3.2/assets/js/chart.min.js (deleted)
-
tags/0.3.2/flywp.php (modified) (2 diffs)
-
tags/0.3.2/includes/Admin.php (modified) (4 diffs)
-
tags/0.3.2/includes/Admin/Adminbar.php (modified) (2 diffs)
-
tags/0.3.2/includes/Admin/Fastcgi_Cache.php (modified) (5 diffs)
-
tags/0.3.2/includes/Admin/Opcache.php (modified) (1 diff)
-
tags/0.3.2/includes/Fastcgi_Cache.php (modified) (1 diff)
-
tags/0.3.2/includes/FlyApi.php (modified) (1 diff)
-
tags/0.3.2/includes/Frontend.php (modified) (1 diff)
-
tags/0.3.2/includes/Opcache.php (modified) (2 diffs)
-
tags/0.3.2/languages/flywp.pot (modified) (6 diffs)
-
tags/0.3.2/readme.txt (modified) (2 diffs)
-
tags/0.3.2/vendor/autoload.php (modified) (1 diff)
-
tags/0.3.2/vendor/composer/autoload_real.php (modified) (2 diffs)
-
tags/0.3.2/vendor/composer/autoload_static.php (modified) (2 diffs)
-
tags/0.3.2/vendor/composer/installed.php (modified) (2 diffs)
-
tags/0.3.2/views/admin.php (modified) (2 diffs)
-
tags/0.3.2/views/op-cache.php (modified) (2 diffs)
-
tags/0.3.2/views/page-cache.php (modified) (1 diff)
-
trunk/assets/css/app.css (modified) (13 diffs)
-
trunk/assets/css/app.min.css (modified) (1 diff)
-
trunk/assets/images (added)
-
trunk/assets/images/flywp-logo.svg (added)
-
trunk/assets/js/admin.js (modified) (1 diff)
-
trunk/assets/js/admin.min.js (modified) (1 diff)
-
trunk/assets/js/chart.min.js (deleted)
-
trunk/flywp.php (modified) (2 diffs)
-
trunk/includes/Admin.php (modified) (4 diffs)
-
trunk/includes/Admin/Adminbar.php (modified) (2 diffs)
-
trunk/includes/Admin/Fastcgi_Cache.php (modified) (5 diffs)
-
trunk/includes/Admin/Opcache.php (modified) (1 diff)
-
trunk/includes/Fastcgi_Cache.php (modified) (1 diff)
-
trunk/includes/FlyApi.php (modified) (1 diff)
-
trunk/includes/Frontend.php (modified) (1 diff)
-
trunk/includes/Opcache.php (modified) (2 diffs)
-
trunk/languages/flywp.pot (modified) (6 diffs)
-
trunk/readme.txt (modified) (2 diffs)
-
trunk/vendor/autoload.php (modified) (1 diff)
-
trunk/vendor/composer/autoload_real.php (modified) (2 diffs)
-
trunk/vendor/composer/autoload_static.php (modified) (2 diffs)
-
trunk/vendor/composer/installed.php (modified) (2 diffs)
-
trunk/views/admin.php (modified) (2 diffs)
-
trunk/views/op-cache.php (modified) (2 diffs)
-
trunk/views/page-cache.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
flywp/tags/0.3.2/assets/css/app.css
r2926989 r2927143 18 18 } 19 19 20 .fw-my-2 {21 margin-top: 0.5rem;22 margin-bottom: 0.5rem;23 }24 25 20 .fw-mb-4 { 26 21 margin-bottom: 1rem; … … 35 30 } 36 31 32 .fw-mr-2 { 33 margin-right: 0.5rem; 34 } 35 37 36 .fw-mt-0 { 38 37 margin-top: 0px; … … 55 54 } 56 55 56 .fw-inline-block { 57 display: inline-block; 58 } 59 57 60 .fw-flex { 58 61 display: flex; … … 63 66 } 64 67 68 .fw-h-11 { 69 height: 2.75rem; 70 } 71 65 72 .fw-w-1\/3 { 66 73 width: 33.333333%; … … 75 82 } 76 83 84 .fw-w-52 { 85 width: 13rem; 86 } 87 77 88 .fw-max-w-xl { 78 89 max-width: 36rem; … … 87 98 } 88 99 100 .fw-justify-end { 101 justify-content: flex-end; 102 } 103 89 104 .fw-justify-between { 90 105 justify-content: space-between; … … 93 108 .fw-gap-3 { 94 109 gap: 0.75rem; 95 }96 97 .fw-space-x-2 > :not([hidden]) ~ :not([hidden]) {98 --tw-space-x-reverse: 0;99 margin-right: calc(0.5rem * var(--tw-space-x-reverse));100 margin-left: calc(0.5rem * calc(1 - var(--tw-space-x-reverse)));101 110 } 102 111 … … 159 168 } 160 169 170 .fw-py-2 { 171 padding-top: 0.5rem; 172 padding-bottom: 0.5rem; 173 } 174 161 175 .fw-py-3 { 162 176 padding-top: 0.75rem; … … 169 183 } 170 184 171 .fw-py-2 {172 padding-top: 0.5rem;173 padding-bottom: 0.5rem;174 }175 176 185 .fw-pb-3 { 177 186 padding-bottom: 0.75rem; … … 182 191 } 183 192 184 .fw- pt-2{185 padding-top: 0.5rem;193 .fw-text-center { 194 text-align: center; 186 195 } 187 196 … … 205 214 } 206 215 216 .fw-font-medium { 217 font-weight: 500; 218 } 219 207 220 .fw-font-semibold { 208 221 font-weight: 600; 209 }210 211 .fw-font-medium {212 font-weight: 500;213 222 } 214 223 … … 248 257 } 249 258 250 body. tools_page_flywp #wpcontent {259 body.dashboard_page_flywp #wpcontent { 251 260 padding-left: 0; 252 261 } 253 262 254 263 @media (min-width: 640px) { 255 .sm\:fw-w-64 { 256 width: 16rem; 257 } 258 259 .sm\:fw-w-20 { 260 width: 5rem; 261 } 262 263 .sm\:fw-w-24 { 264 width: 6rem; 265 } 266 267 .sm\:fw-w-40 { 268 width: 10rem; 269 } 270 271 .sm\:fw-w-28 { 272 width: 7rem; 264 .sm\:fw-mb-0 { 265 margin-bottom: 0px; 266 } 267 268 .sm\:fw-flex { 269 display: flex; 273 270 } 274 271 … … 277 274 } 278 275 276 .sm\:fw-w-1\/3 { 277 width: 33.333333%; 278 } 279 280 .sm\:fw-w-2\/3 { 281 width: 66.666667%; 282 } 283 279 284 .sm\:fw-flex-none { 280 285 flex: none; 281 286 } 282 287 288 .sm\:fw-justify-normal { 289 justify-content: normal; 290 } 291 292 .sm\:fw-px-0 { 293 padding-left: 0px; 294 padding-right: 0px; 295 } 296 283 297 .sm\:fw-pr-6 { 284 298 padding-right: 1.5rem; 285 299 } 286 } 300 301 .sm\:fw-text-right { 302 text-align: right; 303 } 304 } 305 306 @media (min-width: 768px) { 307 .md\:fw-flex { 308 display: flex; 309 } 310 311 .md\:fw-w-1\/3 { 312 width: 33.333333%; 313 } 314 315 .md\:fw-w-2\/3 { 316 width: 66.666667%; 317 } 318 319 .md\:fw-text-right { 320 text-align: right; 321 } 322 } -
flywp/tags/0.3.2/assets/css/app.min.css
r2926998 r2927143 1 .flywp-settings *,.flywp-settings :after,.flywp-settings :before{box-sizing:border-box;border-width:0;border-style:solid}.fw-m-0{margin:0}.fw-mx-auto{margin-left:auto;margin-right:auto}.fw-mb-4{margin-bottom:1rem}.fw-mb-6{margin-bottom:1.5rem}.fw-mb-8{margin-bottom:2rem}.fw-m t-0{margin-top:0}.fw-mt-1{margin-top:.25rem}.fw-mt-2{margin-top:.5rem}.fw-mt-5{margin-top:1.25rem}.fw-block{display:block}.fw-flex{display:flex}.fw-hidden{display:none}.fw-w-1\/3{width:33.333333%}.fw-w-2\/3{width:66.666667%}.fw-w-full{width:100%}.fw-max-w-xl{max-width:36rem}.fw-flex-1{flex:1 1 0%}.fw-items-center{align-items:center}.fw-justify-between{justify-content:space-between}.fw-gap-3{gap:.75rem}.fw-rounded{border-radius:.25rem}.fw-rounded-bl{border-bottom-left-radius:.25rem}.fw-rounded-br{border-bottom-right-radius:.25rem}.fw-border-b{border-bottom-width:1px}.fw-border-t{border-top-width:1px}.fw-border-solid{border-style:solid}.fw-border-gray-200{--tw-border-opacity:1;border-color:rgb(229 231 235/var(--tw-border-opacity))}.fw-bg-gray-100{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity))}.fw-bg-green-200{--tw-bg-opacity:1;background-color:rgb(187 247 208/var(--tw-bg-opacity))}.fw-bg-white{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity))}.fw-p-4{padding:1rem}.fw-px-4{padding-left:1rem;padding-right:1rem}.fw-py-1{padding-top:.25rem;padding-bottom:.25rem}.fw-py-3{padding-top:.75rem;padding-bottom:.75rem}.fw-py-4{padding-top:1rem;padding-bottom:1rem}.fw-pb-3{padding-bottom:.75rem}.fw-pt-4{padding-top:1rem}.fw-text-right{text-align:right}.fw-text-2xl{font-size:1.5rem;line-height:2rem}.fw-text-lg{font-size:1.125rem;line-height:1.75rem}.fw-text-sm{font-size:.875rem;line-height:1.25rem}.fw-font-medium{font-weight:500}.fw-font-semibold{font-weight:600}.fw-leading-6{line-height:1.5rem}.fw-text-gray-400{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity))}.fw-text-gray-500{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity))}.fw-text-gray-900{--tw-text-opacity:1;color:rgb(17 24 39/var(--tw-text-opacity))}.fw-text-green-600{--tw-text-opacity:1;color:rgb(22 163 74/var(--tw-text-opacity))}.fw-text-green-800{--tw-text-opacity:1;color:rgb(22 101 52/var(--tw-text-opacity))}.fw-shadow{--tw-shadow:0 1px 3px 0 #0000001a,0 1px 2px -1px #0000001a;--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color),0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}body.tools_page_flywp #wpcontent{padding-left:0}@media (min-width:640px){.sm\:fw-w-32{width:8rem}.sm\:fw-flex-none{flex:none}.sm\:fw-pr-6{padding-right:1.5rem}}1 .flywp-settings *,.flywp-settings :after,.flywp-settings :before{box-sizing:border-box;border-width:0;border-style:solid}.fw-m-0{margin:0}.fw-mx-auto{margin-left:auto;margin-right:auto}.fw-mb-4{margin-bottom:1rem}.fw-mb-6{margin-bottom:1.5rem}.fw-mb-8{margin-bottom:2rem}.fw-mr-2{margin-right:.5rem}.fw-mt-0{margin-top:0}.fw-mt-1{margin-top:.25rem}.fw-mt-2{margin-top:.5rem}.fw-mt-5{margin-top:1.25rem}.fw-block{display:block}.fw-inline-block{display:inline-block}.fw-flex{display:flex}.fw-hidden{display:none}.fw-h-11{height:2.75rem}.fw-w-full{width:100%}.fw-max-w-xl{max-width:36rem}.fw-flex-1{flex:1 1 0%}.fw-items-center{align-items:center}.fw-justify-between{justify-content:space-between}.fw-gap-3{gap:.75rem}.fw-rounded{border-radius:.25rem}.fw-rounded-bl{border-bottom-left-radius:.25rem}.fw-rounded-br{border-bottom-right-radius:.25rem}.fw-border-b{border-bottom-width:1px}.fw-border-t{border-top-width:1px}.fw-border-solid{border-style:solid}.fw-border-gray-200{--tw-border-opacity:1;border-color:rgb(229 231 235/var(--tw-border-opacity))}.fw-bg-gray-100{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity))}.fw-bg-green-200{--tw-bg-opacity:1;background-color:rgb(187 247 208/var(--tw-bg-opacity))}.fw-bg-white{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity))}.fw-p-4{padding:1rem}.fw-px-4{padding-left:1rem;padding-right:1rem}.fw-py-1{padding-top:.25rem;padding-bottom:.25rem}.fw-py-2{padding-top:.5rem;padding-bottom:.5rem}.fw-py-3{padding-top:.75rem;padding-bottom:.75rem}.fw-py-4{padding-top:1rem;padding-bottom:1rem}.fw-pb-3{padding-bottom:.75rem}.fw-pt-4{padding-top:1rem}.fw-text-center{text-align:center}.fw-text-right{text-align:right}.fw-text-2xl{font-size:1.5rem;line-height:2rem}.fw-text-lg{font-size:1.125rem;line-height:1.75rem}.fw-text-sm{font-size:.875rem;line-height:1.25rem}.fw-font-medium{font-weight:500}.fw-font-semibold{font-weight:600}.fw-leading-6{line-height:1.5rem}.fw-text-gray-400{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity))}.fw-text-gray-500{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity))}.fw-text-gray-900{--tw-text-opacity:1;color:rgb(17 24 39/var(--tw-text-opacity))}.fw-text-green-600{--tw-text-opacity:1;color:rgb(22 163 74/var(--tw-text-opacity))}.fw-text-green-800{--tw-text-opacity:1;color:rgb(22 101 52/var(--tw-text-opacity))}.fw-shadow{--tw-shadow:0 1px 3px 0 #0000001a,0 1px 2px -1px #0000001a;--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color),0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}body.dashboard_page_flywp #wpcontent{padding-left:0}@media (min-width:640px){.sm\:fw-mb-0{margin-bottom:0}.sm\:fw-w-1\/3{width:33.333333%}.sm\:fw-w-2\/3{width:66.666667%}.sm\:fw-w-32{width:8rem}.sm\:fw-flex-none{flex:none}.sm\:fw-justify-normal{justify-content:normal}.sm\:fw-px-0{padding-left:0;padding-right:0}.sm\:fw-pr-6{padding-right:1.5rem}.sm\:fw-text-right{text-align:right}}@media (min-width:768px){.md\:fw-flex{display:flex}.md\:fw-w-1\/3{width:33.333333%}.md\:fw-w-2\/3{width:66.666667%}.md\:fw-text-right{text-align:right}} -
flywp/tags/0.3.2/assets/js/admin.js
r2926989 r2927143 29 29 } 30 30 31 var colors = ['#F87171', '#16a34a', '#FBBF24',];32 var opcacheMemory = $('#opcache-memory'),33 opcacheKeys = $('#opcache-keys'),34 opcacheHits = $('#opcache-hits');35 36 new Chart(opcacheMemory, {37 type: 'doughnut',38 data: {39 labels: ['Used', 'Free', 'Wasted'],40 datasets: [{41 data: [80, 15, 5],42 backgroundColor: colors,43 }],44 hoverOffset: 1045 },46 });47 48 new Chart(opcacheKeys, {49 type: 'doughnut',50 data: {51 labels: ['Used', 'Free', 'Wasted'],52 datasets: [{53 data: [80, 15, 5],54 backgroundColor: colors,55 }],56 hoverOffset: 1057 },58 });59 60 new Chart(opcacheHits, {61 type: 'doughnut',62 data: {63 labels: ['Used', 'Free', 'Wasted'],64 datasets: [{65 data: [80, 15, 5],66 backgroundColor: colors,67 }],68 hoverOffset: 1069 },70 });71 72 31 })(jQuery); -
flywp/tags/0.3.2/assets/js/admin.min.js
r2926998 r2927143 1 !function( t){var a=t("#fastcgi-settings-button"),e=t("#fastcgi-settings-close"),s=t("#fastcgi-settings"),e=(a.on("click",function(e){t(this).toggleClass("active"),t(this).hasClass("active")?s.slideDown("fast"):s.slideUp("fast")}),e.on("click",function(e){a.removeClass("active"),s.slideUp("fast")}),t("#fly-page-cache-notice").length&&setTimeout(function(){t("#fly-page-cache-notice").fadeOut("slow")},2e3),["#F87171","#16a34a","#FBBF24"]),o=t("#opcache-memory"),c=t("#opcache-keys"),n=t("#opcache-hits");new Chart(o,{type:"doughnut",data:{labels:["Used","Free","Wasted"],datasets:[{data:[80,15,5],backgroundColor:e}],hoverOffset:10}}),new Chart(c,{type:"doughnut",data:{labels:["Used","Free","Wasted"],datasets:[{data:[80,15,5],backgroundColor:e}],hoverOffset:10}}),new Chart(n,{type:"doughnut",data:{labels:["Used","Free","Wasted"],datasets:[{data:[80,15,5],backgroundColor:e}],hoverOffset:10}})}(jQuery);1 !function(s){var e=s("#fastcgi-settings-button"),t=s("#fastcgi-settings-close"),i=s("#fastcgi-settings");e.on("click",function(t){s(this).toggleClass("active"),s(this).hasClass("active")?i.slideDown("fast"):i.slideUp("fast")}),t.on("click",function(t){e.removeClass("active"),i.slideUp("fast")}),s("#fly-page-cache-notice").length&&setTimeout(function(){s("#fly-page-cache-notice").fadeOut("slow")},2e3)}(jQuery); -
flywp/tags/0.3.2/flywp.php
r2926998 r2927143 4 4 * Plugin URI: https://flywp.com 5 5 * Description: Helper plugin for FlyWP 6 * Version: 0.3. 16 * Version: 0.3.2 7 7 * Author: FlyWP 8 8 * Author URI: https://flywp.com/?utm_source=wporg&utm_medium=banner&utm_campaign=author-uri … … 42 42 * @var string 43 43 */ 44 public $version = '0.3. 1';44 public $version = '0.3.2'; 45 45 46 46 /** -
flywp/tags/0.3.2/includes/Admin.php
r2926989 r2927143 15 15 * @var string 16 16 */ 17 const SCREEN_NAME = ' tools_page_flywp';17 const SCREEN_NAME = 'dashboard_page_flywp'; 18 18 19 19 public $fastcgi = null; … … 36 36 */ 37 37 public function register_admin_page() { 38 $hook = add_submenu_page( 39 'tools.php', 38 $hook = add_dashboard_page( 40 39 __( 'FlyWP', 'flywp' ), 41 40 __( 'FlyWP', 'flywp' ), … … 56 55 */ 57 56 public function page_url() { 58 return admin_url( ' tools.php?page=' . self::PAGE_SLUG );57 return admin_url( 'index.php?page=' . self::PAGE_SLUG ); 59 58 } 60 59 … … 87 86 $min = defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ? '' : '.min'; 88 87 89 wp_enqueue_script( 'flywp-chart', FLYWP_PLUGIN_URL . '/assets/js/chart.min.js', [], FLYWP_VERSION, true ); 90 wp_enqueue_script( 'flywp-admin-js', FLYWP_PLUGIN_URL . '/assets/js/admin' . $min . '.js', [ 'jquery', 'flywp-chart' ], FLYWP_VERSION, true ); 88 wp_enqueue_script( 'flywp-admin-js', FLYWP_PLUGIN_URL . '/assets/js/admin' . $min . '.js', [ 'jquery' ], FLYWP_VERSION, true ); 91 89 } 92 90 -
flywp/tags/0.3.2/includes/Admin/Adminbar.php
r2925476 r2927143 20 20 */ 21 21 public function admin_bar_menu( $wp_admin_bar ) { 22 if ( ! current_user_can( 'manage_options' ) ) { 23 return; 24 } 25 26 $logo = '<svg viewBox="0 0 44 45" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M22 0.580017C9.85252 0.580017 0 10.4226 0 22.58C0 34.7374 9.85252 44.58 22 44.58C34.1475 44.58 44 34.7275 44 22.58C44 10.4325 34.1475 0.580017 22 0.580017ZM11.0692 27.625C10.9011 27.625 10.7329 27.625 10.5647 27.6052C11.9595 25.0234 14.6799 23.2725 17.8156 23.2725C17.9838 23.2725 18.152 23.2725 18.3201 23.2922C16.9254 25.8741 14.205 27.625 11.0692 27.625ZM32.3273 17.3867L22.5144 32.7194C21.9802 33.7086 20.4964 33.4712 20.2986 32.3633L19.3885 27.4271C19.0126 25.3894 19.8633 23.3318 21.5647 22.1448C21.7428 22.0261 21.8022 21.7886 21.6933 21.6007C21.5944 21.4127 21.3669 21.3237 21.1691 21.4029C19.2005 22.125 17.0045 21.5908 15.58 20.0476L13.2554 17.5351C12.5531 16.7734 13.0971 15.5467 14.1259 15.5467H31.3183C32.268 15.5467 32.8417 16.5953 32.3273 17.3966V17.3867Z" fill="#a7aaad"/></svg>'; 27 $style = 'background-position: 0 6px; color: #fff; background-repeat: no-repeat;background-size: 20px;float: left;height: 30px;width: 26px; background-image: url(data:image/svg+xml;base64,' . base64_encode( $logo ) . ');'; 28 22 29 $wp_admin_bar->add_node( 23 30 [ 24 31 'id' => 'flywp', 25 'title' => __( 'FlyWP', 'flywp' ),26 'href' => flywp()->admin->page_url(),32 'title' => '<div id="flywp-ab-icon" class="flywp-logo svg" style="' . $style . '"></div><span class="ab-label">' . __( 'FlyWP', 'flywp' ) . '</span>', 33 'href' => admin_url( 'index.php?page=flywp' ), 27 34 'parent' => 'top-secondary', 28 35 ] … … 30 37 31 38 if ( flywp()->fastcgi->enabled() ) { 39 if ( ! is_admin() && is_singular() ) { 40 $page_id = get_queried_object_id(); 41 $wp_admin_bar->add_node( 42 [ 43 'id' => 'flywp-cache-single', 44 'title' => __( 'Clear This Page Cache', 'flywp' ), 45 'href' => flywp()->fastcgi->purge_cache_url() . '&page_id=' . $page_id, 46 'parent' => 'flywp', 47 ] 48 ); 49 } 50 32 51 $wp_admin_bar->add_node( 33 52 [ 34 53 'id' => 'flywp-cache', 35 54 'title' => __( 'Clear Page Cache', 'flywp' ), 36 'href' => flywp()-> admin->fastcgi->purge_cache_url(),55 'href' => flywp()->fastcgi->purge_cache_url(), 37 56 'parent' => 'flywp', 38 57 ] 39 58 ); 40 59 } 60 61 if ( flywp()->opcache->enabled() ) { 62 $wp_admin_bar->add_node( 63 [ 64 'id' => 'flywp-opcache', 65 'title' => __( 'Clear OPcache', 'flywp' ), 66 'href' => flywp()->opcache->purge_cache_url(), 67 'parent' => 'flywp', 68 ] 69 ); 70 } 71 72 $wp_admin_bar->add_node( 73 [ 74 'id' => 'flywp-settings', 75 'title' => __( 'Settings', 'flywp' ), 76 'href' => admin_url( 'index.php?page=flywp' ), 77 'parent' => 'flywp', 78 ] 79 ); 41 80 } 42 81 } -
flywp/tags/0.3.2/includes/Admin/Fastcgi_Cache.php
r2926989 r2927143 4 4 5 5 use FlyWP\Admin; 6 use FlyWP\Helper;7 6 8 7 class Fastcgi_Cache { … … 15 14 add_action( 'load-' . Admin::SCREEN_NAME, [ $this, 'handle_cleanup' ] ); 16 15 add_action( 'load-' . Admin::SCREEN_NAME, [ $this, 'handle_enable_disable' ] ); 17 }18 19 /**20 * FastCGI cache purge url.21 *22 * @return string23 */24 public function purge_cache_url() {25 return wp_nonce_url(26 add_query_arg(27 [ 'flywp-action' => 'purge-fastcgi-cache' ],28 flywp()->admin->page_url()29 ),30 'fly-fastcgi-purge-cache'31 );32 16 } 33 17 … … 70 54 } 71 55 72 flywp()->fastcgi->clear_cache();56 $page_id = isset( $_GET['page_id'] ) ? absint( $_GET['page_id'] ) : 0; 73 57 74 wp_safe_redirect( admin_url( 'tools.php?page=flywp&fly-notice=fastcgi-purged' ) ); 58 if ( $page_id ) { 59 flywp()->fastcgi->purge_cache_by_url( get_permalink( $page_id ) ); 60 } else { 61 flywp()->fastcgi->clear_cache(); 62 } 63 64 wp_safe_redirect( admin_url( 'index.php?page=flywp&fly-notice=fastcgi-purged' ) ); 75 65 exit; 76 66 } … … 111 101 update_option( flywp()->fastcgi::SETTINGS_KEY, $settings ); 112 102 113 wp_safe_redirect( admin_url( ' tools.php?page=flywp&fly-notice=fastcgi-saved' ) );103 wp_safe_redirect( admin_url( 'index.php?page=flywp&fly-notice=fastcgi-saved' ) ); 114 104 exit; 115 105 } … … 140 130 $notice = $type === 'enable' ? 'fastcgi-enabled' : 'fastcgi-disabled'; 141 131 142 // Toggle cache in the API143 132 $reponse = flywp()->flyapi->cache_toggle( $type ); 144 // Helper::dd( $reponse );145 133 146 134 update_option( flywp()->fastcgi::SETTINGS_KEY, $settings ); 147 135 148 wp_safe_redirect( admin_url( ' tools.php?page=flywp&fly-notice=' . $notice ) );136 wp_safe_redirect( admin_url( 'index.php?page=flywp&fly-notice=' . $notice ) ); 149 137 exit; 150 138 } -
flywp/tags/0.3.2/includes/Admin/Opcache.php
r2926989 r2927143 34 34 flywp()->opcache->clear(); 35 35 36 wp_safe_redirect( admin_url( ' tools.php?page=flywp&fly-notice=opcache-purged' ) );36 wp_safe_redirect( admin_url( 'index.php?page=flywp&fly-notice=opcache-purged' ) ); 37 37 exit; 38 38 } -
flywp/tags/0.3.2/includes/Fastcgi_Cache.php
r2926989 r2927143 26 26 // add_action( 'edited_term', [ $this, 'purge_taxonomy_cache' ], 10, 2 ); 27 27 // add_action( 'wp_update_nav_menu', [ $this, 'purge_home_cache' ], 10, 2 ); 28 } 29 30 /** 31 * FastCGI cache purge url. 32 * 33 * @return string 34 */ 35 public function purge_cache_url() { 36 return wp_nonce_url( 37 add_query_arg( 38 [ 'flywp-action' => 'purge-fastcgi-cache' ], 39 admin_url( 'index.php?page=flywp' ) 40 ), 41 'fly-fastcgi-purge-cache' 42 ); 28 43 } 29 44 -
flywp/tags/0.3.2/includes/FlyApi.php
r2925476 r2927143 91 91 92 92 if ( is_wp_error( $response ) ) { 93 // Handle error if needed94 93 return false; 95 94 } -
flywp/tags/0.3.2/includes/Frontend.php
r2910491 r2927143 12 12 public function __construct() { 13 13 new Frontend\MagicLogin(); 14 new Admin\Adminbar(); 14 15 } 15 16 } -
flywp/tags/0.3.2/includes/Opcache.php
r2926989 r2927143 5 5 class Opcache { 6 6 7 /** 8 * Opcache constructor. 9 */ 7 10 public function clear() { 8 11 return opcache_reset(); 9 12 } 10 13 14 /** 15 * Check if opcache is available. 16 * 17 * @return bool 18 */ 11 19 public function has_opcache() { 12 20 return function_exists( 'opcache_get_status' ); 13 21 } 14 22 23 /** 24 * Get opcache status. 25 * 26 * @return array 27 */ 15 28 public function get_status() { 16 29 return opcache_get_status(); 17 30 } 18 31 32 /** 33 * Get opcache config. 34 * 35 * @return array 36 */ 19 37 public function get_config() { 20 38 return opcache_get_configuration(); 21 39 } 22 40 41 /** 42 * Check if opcache is enabled. 43 * 44 * @return bool 45 */ 23 46 public function enabled() { 24 47 if ( ! $this->has_opcache() ) { … … 31 54 } 32 55 56 /** 57 * Get OPcache purge URL. 58 * 59 * @return string 60 */ 33 61 public function purge_cache_url() { 34 62 return wp_nonce_url( 35 63 add_query_arg( 36 64 [ 'flywp-action' => 'purge-opcache' ], 37 flywp()->admin->page_url()65 admin_url( 'index.php?page=flywp' ), 38 66 ), 39 67 'fly-opcache-purge' -
flywp/tags/0.3.2/languages/flywp.pot
r2926998 r2927143 2 2 msgid "" 3 3 msgstr "" 4 "Project-Id-Version: FlyWP 0.3. 1\n"4 "Project-Id-Version: FlyWP 0.3.2\n" 5 5 "Report-Msgid-Bugs-To: https://github.com/flywp/flywp-helper/issues\n" 6 6 "Last-Translator: [email protected]\n" … … 9 9 "Content-Type: text/plain; charset=UTF-8\n" 10 10 "Content-Transfer-Encoding: 8bit\n" 11 "POT-Creation-Date: 2023-06-16T 09:23:52+00:00\n"11 "POT-Creation-Date: 2023-06-16T15:39:14+00:00\n" 12 12 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" 13 13 "X-Generator: WP-CLI 2.7.1\n" … … 34 34 msgstr "" 35 35 36 msgid "Clear This Page Cache" 37 msgstr "" 38 36 39 msgid "Clear Page Cache" 40 msgstr "" 41 42 msgid "Clear OPcache" 43 msgstr "" 44 45 msgid "Settings" 37 46 msgstr "" 38 47 … … 41 50 42 51 msgid "You do not have permission to purge the opcache." 43 msgstr ""44 45 msgid "Settings"46 52 msgstr "" 47 53 … … 55 61 msgstr "" 56 62 63 msgid "FlyWP Dashboard" 64 msgstr "" 65 57 66 msgid "PHP OPcache has been cleared." 58 67 msgstr "" 59 68 60 msgid "PHP O pcache"69 msgid "PHP OPcache" 61 70 msgstr "" 62 71 … … 68 77 69 78 msgid "OPcache improves PHP performance by storing precompiled script bytecode in shared memory, thereby removing the need for PHP to load and parse scripts on each request." 79 msgstr "" 80 81 msgid "Hit Rate" 82 msgstr "" 83 84 msgid "Cached Scripts" 85 msgstr "" 86 87 msgid "Memory" 88 msgstr "" 89 90 msgid "Keys" 91 msgstr "" 92 93 msgid "Engine" 70 94 msgstr "" 71 95 -
flywp/tags/0.3.2/readme.txt
r2926998 r2927143 5 5 Tested up to: 6.2 6 6 Requires PHP: 7.4 7 Stable tag: 0.3. 17 Stable tag: 0.3.2 8 8 Requires PHP: 7.1 or higher 9 9 License: GPLv2 or later … … 52 52 53 53 1. FlyWP settings page. 54 2. Cloud server management dashboard.55 3. Caching settings and controls.56 54 57 55 == Changelog == 56 57 = v0.3.2 (16 June, 2023) = 58 59 * **Fix:** Removed unused Chart.js library. 60 * **Improved:** The admin bar is improved with logo and a settings page. Now it shows on the frontend too, with singular resource clear link. 61 * **Improved:** The settings page has moved to the Dashboard menu. It's responsive now and has a logo. 58 62 59 63 = v0.3.1 (16 June, 2023) = -
flywp/tags/0.3.2/vendor/autoload.php
r2926998 r2927143 23 23 require_once __DIR__ . '/composer/autoload_real.php'; 24 24 25 return ComposerAutoloaderInit cc227957e42c2818fe0f5977f8d16a8d::getLoader();25 return ComposerAutoloaderInitedc10cb8386cda1f9e804abee7ed7720::getLoader(); -
flywp/tags/0.3.2/vendor/composer/autoload_real.php
r2926998 r2927143 3 3 // autoload_real.php @generated by Composer 4 4 5 class ComposerAutoloaderInit cc227957e42c2818fe0f5977f8d16a8d5 class ComposerAutoloaderInitedc10cb8386cda1f9e804abee7ed7720 6 6 { 7 7 private static $loader; … … 23 23 } 24 24 25 spl_autoload_register(array('ComposerAutoloaderInit cc227957e42c2818fe0f5977f8d16a8d', 'loadClassLoader'), true, true);25 spl_autoload_register(array('ComposerAutoloaderInitedc10cb8386cda1f9e804abee7ed7720', 'loadClassLoader'), true, true); 26 26 self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__)); 27 spl_autoload_unregister(array('ComposerAutoloaderInit cc227957e42c2818fe0f5977f8d16a8d', 'loadClassLoader'));27 spl_autoload_unregister(array('ComposerAutoloaderInitedc10cb8386cda1f9e804abee7ed7720', 'loadClassLoader')); 28 28 29 29 require __DIR__ . '/autoload_static.php'; 30 call_user_func(\Composer\Autoload\ComposerStaticInit cc227957e42c2818fe0f5977f8d16a8d::getInitializer($loader));30 call_user_func(\Composer\Autoload\ComposerStaticInitedc10cb8386cda1f9e804abee7ed7720::getInitializer($loader)); 31 31 32 32 $loader->register(true); -
flywp/tags/0.3.2/vendor/composer/autoload_static.php
r2926998 r2927143 5 5 namespace Composer\Autoload; 6 6 7 class ComposerStaticInit cc227957e42c2818fe0f5977f8d16a8d7 class ComposerStaticInitedc10cb8386cda1f9e804abee7ed7720 8 8 { 9 9 public static $prefixLengthsPsr4 = array ( … … 57 57 { 58 58 return \Closure::bind(function () use ($loader) { 59 $loader->prefixLengthsPsr4 = ComposerStaticInit cc227957e42c2818fe0f5977f8d16a8d::$prefixLengthsPsr4;60 $loader->prefixDirsPsr4 = ComposerStaticInit cc227957e42c2818fe0f5977f8d16a8d::$prefixDirsPsr4;61 $loader->classMap = ComposerStaticInit cc227957e42c2818fe0f5977f8d16a8d::$classMap;59 $loader->prefixLengthsPsr4 = ComposerStaticInitedc10cb8386cda1f9e804abee7ed7720::$prefixLengthsPsr4; 60 $loader->prefixDirsPsr4 = ComposerStaticInitedc10cb8386cda1f9e804abee7ed7720::$prefixDirsPsr4; 61 $loader->classMap = ComposerStaticInitedc10cb8386cda1f9e804abee7ed7720::$classMap; 62 62 63 63 }, null, ClassLoader::class); -
flywp/tags/0.3.2/vendor/composer/installed.php
r2926998 r2927143 2 2 'root' => array( 3 3 'name' => 'flywp/flywp', 4 'pretty_version' => '0.3. 1',5 'version' => '0.3. 1.0',4 'pretty_version' => '0.3.2', 5 'version' => '0.3.2.0', 6 6 'reference' => NULL, 7 7 'type' => 'wordpress-plugin', … … 12 12 'versions' => array( 13 13 'flywp/flywp' => array( 14 'pretty_version' => '0.3. 1',15 'version' => '0.3. 1.0',14 'pretty_version' => '0.3.2', 15 'version' => '0.3.2.0', 16 16 'reference' => NULL, 17 17 'type' => 'wordpress-plugin', -
flywp/tags/0.3.2/views/admin.php
r2926989 r2927143 1 1 <div class="flywp-settings" id="flywp-settings"> 2 2 <div class="fw-mb-8 fw-bg-white fw-border-b fw-border-solid fw-border-gray-200"> 3 <div class="fw-max-w-xl fw-mx-auto"> 4 <div class="fw-flex fw-py-4 fw-items-center fw-justify-between"> 5 <h1 class="fw-text-2xl fw-font-semibold fw-flex-1">FlyWP</h1> 3 <div class="fw-max-w-xl fw-mx-auto fw-px-4 sm:fw-px-0"> 4 <div class="fw-flex fw-py-2 fw-items-center fw-justify-between"> 5 <h1 class="fw-text-2xl fw-font-semibold fw-flex-1"> 6 <img src="<?php echo esc_url( FLYWP_PLUGIN_URL . 'assets/images/flywp-logo.svg' ); ?>" alt="FlyWP" class="fw-h-11 fw-mr-2 fw-inline-block"> 7 </h1> 6 8 7 9 <div class=""> 8 <a href="https://app.flywp.com" target="_blank" class="button button-secondary"><span class="dashicons dashicons-external fw-mt-1"></span> FlyWP Dashboard</a>10 <a href="https://app.flywp.com" target="_blank" class="button button-secondary"><span class="dashicons dashicons-external fw-mt-1"></span> <?php esc_html_e( 'FlyWP Dashboard', 'flywp' ); ?></a> 9 11 </div> 10 12 </div> … … 12 14 </div> 13 15 14 <div class="fw-max-w-xl fw-mx-auto ">16 <div class="fw-max-w-xl fw-mx-auto fw-px-4 sm:fw-px-0"> 15 17 <?php require __DIR__ . '/page-cache.php'; ?> 16 18 <?php require __DIR__ . '/op-cache.php'; ?> -
flywp/tags/0.3.2/views/op-cache.php
r2926989 r2927143 18 18 <div class="fw-flex fw-px-4 fw-py-4 fw-fw-sm:p-6 fw-items-center fw-justify-between fw-border-b fw-border-gray-200"> 19 19 <h3 class="fw-text-lg fw-font-semibold fw-leading-6 fw-text-gray-900 fw-m-0"> 20 <?php esc_html_e( 'PHP O pcache', 'flywp' ); ?>20 <?php esc_html_e( 'PHP OPcache', 'flywp' ); ?> 21 21 </h3> 22 22 … … 44 44 <p class="fw-mt-0"><?php esc_html_e( 'OPcache improves PHP performance by storing precompiled script bytecode in shared memory, thereby removing the need for PHP to load and parse scripts on each request.', 'flywp' ); ?></p> 45 45 46 47 <div class="fw-flex fw-w-full fw-mb-4 fw-gap-3 fw-items-center">48 <div class="fw-w-2/3">49 <dl class="fw-m-0 fw-mt-2">50 <div class="fw-flex fw-w-full">51 <dt class="fw-font-medium fw-text-gray-900 sm:fw-w-32 sm:fw-flex-none sm:fw-pr-6">Hit Rate</dt>52 <dd><?php echo number_format( $status['opcache_statistics']['opcache_hit_rate'], 2 ) . '%'; ?></dd>53 </div>46 <?php if ( flywp()->opcache->enabled() ) { ?> 47 <div class="md:fw-flex fw-w-full fw-mb-4 fw-gap-3 fw-items-center"> 48 <div class="sm:fw-w-2/3 fw-mb-6 sm:fw-mb-0"> 49 <dl class="fw-m-0 fw-mt-2"> 50 <div class="fw-flex fw-justify-between sm:fw-justify-normal"> 51 <dt class="fw-font-medium fw-text-gray-900 sm:fw-w-32 sm:fw-flex-none sm:fw-pr-6"><?php esc_html_e( 'Hit Rate', 'flywp' ); ?></dt> 52 <dd><?php echo number_format( $status['opcache_statistics']['opcache_hit_rate'], 2 ) . '%'; ?></dd> 53 </div> 54 54 55 <div class="fw-flex">56 <dt class="fw-font-medium fw-text-gray-900 sm:fw-w-32 sm:fw-pr-6">Cached Scripts</dt>57 <dd><?php echo $status['opcache_statistics']['num_cached_scripts']; ?></dd>58 </div>55 <div class="fw-flex fw-justify-between sm:fw-justify-normal"> 56 <dt class="fw-font-medium fw-text-gray-900 sm:fw-w-32 sm:fw-pr-6"><?php esc_html_e( 'Cached Scripts', 'flywp' ); ?></dt> 57 <dd><?php echo $status['opcache_statistics']['num_cached_scripts']; ?></dd> 58 </div> 59 59 60 <div class="fw-flex">61 <dt class="fw-font-medium fw-text-gray-900 sm:fw-w-32 sm:fw-pr-6">Memory</dt>62 <dd><?php echo sprintf( '%s of %s', size_format( $status['memory_usage']['used_memory'] ), size_format( $config['directives']['opcache.memory_consumption'] ) ); ?></dd>63 </div>60 <div class="fw-flex fw-justify-between sm:fw-justify-normal"> 61 <dt class="fw-font-medium fw-text-gray-900 sm:fw-w-32 sm:fw-pr-6"><?php esc_html_e( 'Memory', 'flywp' ); ?></dt> 62 <dd><?php echo sprintf( '%s of %s', size_format( $status['memory_usage']['used_memory'] ), size_format( $config['directives']['opcache.memory_consumption'] ) ); ?></dd> 63 </div> 64 64 65 <div class="fw-flex">66 <dt class="fw-font-medium fw-text-gray-900 sm:fw-w-32 sm:fw-pr-6">Keys</dt>67 <dd><?php echo sprintf( '%d of %d', $status['opcache_statistics']['num_cached_keys'], $status['opcache_statistics']['max_cached_keys'] ); ?></dd>68 </div>65 <div class="fw-flex fw-justify-between sm:fw-justify-normal"> 66 <dt class="fw-font-medium fw-text-gray-900 sm:fw-w-32 sm:fw-pr-6"><?php esc_html_e( 'Keys', 'flywp' ); ?></dt> 67 <dd><?php echo sprintf( '%d of %d', $status['opcache_statistics']['num_cached_keys'], $status['opcache_statistics']['max_cached_keys'] ); ?></dd> 68 </div> 69 69 70 <div class="fw-flex">71 <dt class="fw-font-medium fw-text-gray-900 sm:fw-w-32 sm:fw-pr-6">Engine</dt>72 <dd><?php echo sprintf( '%s (%s)', $config['version']['opcache_product_name'], $config['version']['version'] ); ?></dd>73 </div>74 </dl>75 </div>70 <div class="fw-flex fw-justify-between sm:fw-justify-normal"> 71 <dt class="fw-font-medium fw-text-gray-900 sm:fw-w-32 sm:fw-pr-6"><?php esc_html_e( 'Engine', 'flywp' ); ?></dt> 72 <dd><?php echo sprintf( '%s (%s)', $config['version']['opcache_product_name'], $config['version']['version'] ); ?></dd> 73 </div> 74 </dl> 75 </div> 76 76 77 <?php if ( flywp()->opcache->enabled() ) { ?> 78 <div class="fw-w-1/3"> 77 <div class="sm:fw-w-1/3 fw-text-center sm:fw-text-right"> 79 78 <a href="<?php echo esc_url( flywp()->opcache->purge_cache_url() ); ?>" class="button button-primary button-hero"><?php esc_html_e( 'Clear Cache', 'flywp' ); ?></a> 80 79 </div> 81 <?php } ?> 82 </div> 83 84 80 </div> 81 <?php } ?> 85 82 </div> 86 83 </div> -
flywp/tags/0.3.2/views/page-cache.php
r2926989 r2927143 42 42 <?php } ?> 43 43 44 <div class="fw-mt-2 fw-px-4 fw-py-4 fw-fw-sm:p-6 fw-text-sm fw-text-gray-500 fw-flex">45 <div class=" fw-w-2/3">44 <div class="fw-mt-2 fw-px-4 fw-py-4 fw-fw-sm:p-6 fw-text-sm fw-text-gray-500 md:fw-flex"> 45 <div class="md:fw-w-2/3"> 46 46 <p class="fw-mt-0"><?php esc_html_e( 'Nginx FastCGI Cache is a very fast page caching system that boosts up your website page load speed. It\'s recommended to enable the page cache.', 'flywp' ); ?></p> 47 47 </div> 48 48 49 49 <?php if ( flywp()->fastcgi->enabled() ) { ?> 50 <div class=" fw-w-1/3fw-text-right">51 <a href="<?php echo esc_url( $this->fastcgi->purge_cache_url() ); ?>" class="button button-primary button-hero"><?php esc_html_e( 'Clear Cache', 'flywp' ); ?></a>50 <div class="md:fw-w-1/3 fw-text-center md:fw-text-right"> 51 <a href="<?php echo esc_url( flywp()->fastcgi->purge_cache_url() ); ?>" class="button button-primary button-hero"><?php esc_html_e( 'Clear Cache', 'flywp' ); ?></a> 52 52 </div> 53 53 <?php } ?> -
flywp/trunk/assets/css/app.css
r2926989 r2927143 18 18 } 19 19 20 .fw-my-2 {21 margin-top: 0.5rem;22 margin-bottom: 0.5rem;23 }24 25 20 .fw-mb-4 { 26 21 margin-bottom: 1rem; … … 35 30 } 36 31 32 .fw-mr-2 { 33 margin-right: 0.5rem; 34 } 35 37 36 .fw-mt-0 { 38 37 margin-top: 0px; … … 55 54 } 56 55 56 .fw-inline-block { 57 display: inline-block; 58 } 59 57 60 .fw-flex { 58 61 display: flex; … … 63 66 } 64 67 68 .fw-h-11 { 69 height: 2.75rem; 70 } 71 65 72 .fw-w-1\/3 { 66 73 width: 33.333333%; … … 75 82 } 76 83 84 .fw-w-52 { 85 width: 13rem; 86 } 87 77 88 .fw-max-w-xl { 78 89 max-width: 36rem; … … 87 98 } 88 99 100 .fw-justify-end { 101 justify-content: flex-end; 102 } 103 89 104 .fw-justify-between { 90 105 justify-content: space-between; … … 93 108 .fw-gap-3 { 94 109 gap: 0.75rem; 95 }96 97 .fw-space-x-2 > :not([hidden]) ~ :not([hidden]) {98 --tw-space-x-reverse: 0;99 margin-right: calc(0.5rem * var(--tw-space-x-reverse));100 margin-left: calc(0.5rem * calc(1 - var(--tw-space-x-reverse)));101 110 } 102 111 … … 159 168 } 160 169 170 .fw-py-2 { 171 padding-top: 0.5rem; 172 padding-bottom: 0.5rem; 173 } 174 161 175 .fw-py-3 { 162 176 padding-top: 0.75rem; … … 169 183 } 170 184 171 .fw-py-2 {172 padding-top: 0.5rem;173 padding-bottom: 0.5rem;174 }175 176 185 .fw-pb-3 { 177 186 padding-bottom: 0.75rem; … … 182 191 } 183 192 184 .fw- pt-2{185 padding-top: 0.5rem;193 .fw-text-center { 194 text-align: center; 186 195 } 187 196 … … 205 214 } 206 215 216 .fw-font-medium { 217 font-weight: 500; 218 } 219 207 220 .fw-font-semibold { 208 221 font-weight: 600; 209 }210 211 .fw-font-medium {212 font-weight: 500;213 222 } 214 223 … … 248 257 } 249 258 250 body. tools_page_flywp #wpcontent {259 body.dashboard_page_flywp #wpcontent { 251 260 padding-left: 0; 252 261 } 253 262 254 263 @media (min-width: 640px) { 255 .sm\:fw-w-64 { 256 width: 16rem; 257 } 258 259 .sm\:fw-w-20 { 260 width: 5rem; 261 } 262 263 .sm\:fw-w-24 { 264 width: 6rem; 265 } 266 267 .sm\:fw-w-40 { 268 width: 10rem; 269 } 270 271 .sm\:fw-w-28 { 272 width: 7rem; 264 .sm\:fw-mb-0 { 265 margin-bottom: 0px; 266 } 267 268 .sm\:fw-flex { 269 display: flex; 273 270 } 274 271 … … 277 274 } 278 275 276 .sm\:fw-w-1\/3 { 277 width: 33.333333%; 278 } 279 280 .sm\:fw-w-2\/3 { 281 width: 66.666667%; 282 } 283 279 284 .sm\:fw-flex-none { 280 285 flex: none; 281 286 } 282 287 288 .sm\:fw-justify-normal { 289 justify-content: normal; 290 } 291 292 .sm\:fw-px-0 { 293 padding-left: 0px; 294 padding-right: 0px; 295 } 296 283 297 .sm\:fw-pr-6 { 284 298 padding-right: 1.5rem; 285 299 } 286 } 300 301 .sm\:fw-text-right { 302 text-align: right; 303 } 304 } 305 306 @media (min-width: 768px) { 307 .md\:fw-flex { 308 display: flex; 309 } 310 311 .md\:fw-w-1\/3 { 312 width: 33.333333%; 313 } 314 315 .md\:fw-w-2\/3 { 316 width: 66.666667%; 317 } 318 319 .md\:fw-text-right { 320 text-align: right; 321 } 322 } -
flywp/trunk/assets/css/app.min.css
r2926998 r2927143 1 .flywp-settings *,.flywp-settings :after,.flywp-settings :before{box-sizing:border-box;border-width:0;border-style:solid}.fw-m-0{margin:0}.fw-mx-auto{margin-left:auto;margin-right:auto}.fw-mb-4{margin-bottom:1rem}.fw-mb-6{margin-bottom:1.5rem}.fw-mb-8{margin-bottom:2rem}.fw-m t-0{margin-top:0}.fw-mt-1{margin-top:.25rem}.fw-mt-2{margin-top:.5rem}.fw-mt-5{margin-top:1.25rem}.fw-block{display:block}.fw-flex{display:flex}.fw-hidden{display:none}.fw-w-1\/3{width:33.333333%}.fw-w-2\/3{width:66.666667%}.fw-w-full{width:100%}.fw-max-w-xl{max-width:36rem}.fw-flex-1{flex:1 1 0%}.fw-items-center{align-items:center}.fw-justify-between{justify-content:space-between}.fw-gap-3{gap:.75rem}.fw-rounded{border-radius:.25rem}.fw-rounded-bl{border-bottom-left-radius:.25rem}.fw-rounded-br{border-bottom-right-radius:.25rem}.fw-border-b{border-bottom-width:1px}.fw-border-t{border-top-width:1px}.fw-border-solid{border-style:solid}.fw-border-gray-200{--tw-border-opacity:1;border-color:rgb(229 231 235/var(--tw-border-opacity))}.fw-bg-gray-100{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity))}.fw-bg-green-200{--tw-bg-opacity:1;background-color:rgb(187 247 208/var(--tw-bg-opacity))}.fw-bg-white{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity))}.fw-p-4{padding:1rem}.fw-px-4{padding-left:1rem;padding-right:1rem}.fw-py-1{padding-top:.25rem;padding-bottom:.25rem}.fw-py-3{padding-top:.75rem;padding-bottom:.75rem}.fw-py-4{padding-top:1rem;padding-bottom:1rem}.fw-pb-3{padding-bottom:.75rem}.fw-pt-4{padding-top:1rem}.fw-text-right{text-align:right}.fw-text-2xl{font-size:1.5rem;line-height:2rem}.fw-text-lg{font-size:1.125rem;line-height:1.75rem}.fw-text-sm{font-size:.875rem;line-height:1.25rem}.fw-font-medium{font-weight:500}.fw-font-semibold{font-weight:600}.fw-leading-6{line-height:1.5rem}.fw-text-gray-400{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity))}.fw-text-gray-500{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity))}.fw-text-gray-900{--tw-text-opacity:1;color:rgb(17 24 39/var(--tw-text-opacity))}.fw-text-green-600{--tw-text-opacity:1;color:rgb(22 163 74/var(--tw-text-opacity))}.fw-text-green-800{--tw-text-opacity:1;color:rgb(22 101 52/var(--tw-text-opacity))}.fw-shadow{--tw-shadow:0 1px 3px 0 #0000001a,0 1px 2px -1px #0000001a;--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color),0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}body.tools_page_flywp #wpcontent{padding-left:0}@media (min-width:640px){.sm\:fw-w-32{width:8rem}.sm\:fw-flex-none{flex:none}.sm\:fw-pr-6{padding-right:1.5rem}}1 .flywp-settings *,.flywp-settings :after,.flywp-settings :before{box-sizing:border-box;border-width:0;border-style:solid}.fw-m-0{margin:0}.fw-mx-auto{margin-left:auto;margin-right:auto}.fw-mb-4{margin-bottom:1rem}.fw-mb-6{margin-bottom:1.5rem}.fw-mb-8{margin-bottom:2rem}.fw-mr-2{margin-right:.5rem}.fw-mt-0{margin-top:0}.fw-mt-1{margin-top:.25rem}.fw-mt-2{margin-top:.5rem}.fw-mt-5{margin-top:1.25rem}.fw-block{display:block}.fw-inline-block{display:inline-block}.fw-flex{display:flex}.fw-hidden{display:none}.fw-h-11{height:2.75rem}.fw-w-full{width:100%}.fw-max-w-xl{max-width:36rem}.fw-flex-1{flex:1 1 0%}.fw-items-center{align-items:center}.fw-justify-between{justify-content:space-between}.fw-gap-3{gap:.75rem}.fw-rounded{border-radius:.25rem}.fw-rounded-bl{border-bottom-left-radius:.25rem}.fw-rounded-br{border-bottom-right-radius:.25rem}.fw-border-b{border-bottom-width:1px}.fw-border-t{border-top-width:1px}.fw-border-solid{border-style:solid}.fw-border-gray-200{--tw-border-opacity:1;border-color:rgb(229 231 235/var(--tw-border-opacity))}.fw-bg-gray-100{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity))}.fw-bg-green-200{--tw-bg-opacity:1;background-color:rgb(187 247 208/var(--tw-bg-opacity))}.fw-bg-white{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity))}.fw-p-4{padding:1rem}.fw-px-4{padding-left:1rem;padding-right:1rem}.fw-py-1{padding-top:.25rem;padding-bottom:.25rem}.fw-py-2{padding-top:.5rem;padding-bottom:.5rem}.fw-py-3{padding-top:.75rem;padding-bottom:.75rem}.fw-py-4{padding-top:1rem;padding-bottom:1rem}.fw-pb-3{padding-bottom:.75rem}.fw-pt-4{padding-top:1rem}.fw-text-center{text-align:center}.fw-text-right{text-align:right}.fw-text-2xl{font-size:1.5rem;line-height:2rem}.fw-text-lg{font-size:1.125rem;line-height:1.75rem}.fw-text-sm{font-size:.875rem;line-height:1.25rem}.fw-font-medium{font-weight:500}.fw-font-semibold{font-weight:600}.fw-leading-6{line-height:1.5rem}.fw-text-gray-400{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity))}.fw-text-gray-500{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity))}.fw-text-gray-900{--tw-text-opacity:1;color:rgb(17 24 39/var(--tw-text-opacity))}.fw-text-green-600{--tw-text-opacity:1;color:rgb(22 163 74/var(--tw-text-opacity))}.fw-text-green-800{--tw-text-opacity:1;color:rgb(22 101 52/var(--tw-text-opacity))}.fw-shadow{--tw-shadow:0 1px 3px 0 #0000001a,0 1px 2px -1px #0000001a;--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color),0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}body.dashboard_page_flywp #wpcontent{padding-left:0}@media (min-width:640px){.sm\:fw-mb-0{margin-bottom:0}.sm\:fw-w-1\/3{width:33.333333%}.sm\:fw-w-2\/3{width:66.666667%}.sm\:fw-w-32{width:8rem}.sm\:fw-flex-none{flex:none}.sm\:fw-justify-normal{justify-content:normal}.sm\:fw-px-0{padding-left:0;padding-right:0}.sm\:fw-pr-6{padding-right:1.5rem}.sm\:fw-text-right{text-align:right}}@media (min-width:768px){.md\:fw-flex{display:flex}.md\:fw-w-1\/3{width:33.333333%}.md\:fw-w-2\/3{width:66.666667%}.md\:fw-text-right{text-align:right}} -
flywp/trunk/assets/js/admin.js
r2926989 r2927143 29 29 } 30 30 31 var colors = ['#F87171', '#16a34a', '#FBBF24',];32 var opcacheMemory = $('#opcache-memory'),33 opcacheKeys = $('#opcache-keys'),34 opcacheHits = $('#opcache-hits');35 36 new Chart(opcacheMemory, {37 type: 'doughnut',38 data: {39 labels: ['Used', 'Free', 'Wasted'],40 datasets: [{41 data: [80, 15, 5],42 backgroundColor: colors,43 }],44 hoverOffset: 1045 },46 });47 48 new Chart(opcacheKeys, {49 type: 'doughnut',50 data: {51 labels: ['Used', 'Free', 'Wasted'],52 datasets: [{53 data: [80, 15, 5],54 backgroundColor: colors,55 }],56 hoverOffset: 1057 },58 });59 60 new Chart(opcacheHits, {61 type: 'doughnut',62 data: {63 labels: ['Used', 'Free', 'Wasted'],64 datasets: [{65 data: [80, 15, 5],66 backgroundColor: colors,67 }],68 hoverOffset: 1069 },70 });71 72 31 })(jQuery); -
flywp/trunk/assets/js/admin.min.js
r2926998 r2927143 1 !function( t){var a=t("#fastcgi-settings-button"),e=t("#fastcgi-settings-close"),s=t("#fastcgi-settings"),e=(a.on("click",function(e){t(this).toggleClass("active"),t(this).hasClass("active")?s.slideDown("fast"):s.slideUp("fast")}),e.on("click",function(e){a.removeClass("active"),s.slideUp("fast")}),t("#fly-page-cache-notice").length&&setTimeout(function(){t("#fly-page-cache-notice").fadeOut("slow")},2e3),["#F87171","#16a34a","#FBBF24"]),o=t("#opcache-memory"),c=t("#opcache-keys"),n=t("#opcache-hits");new Chart(o,{type:"doughnut",data:{labels:["Used","Free","Wasted"],datasets:[{data:[80,15,5],backgroundColor:e}],hoverOffset:10}}),new Chart(c,{type:"doughnut",data:{labels:["Used","Free","Wasted"],datasets:[{data:[80,15,5],backgroundColor:e}],hoverOffset:10}}),new Chart(n,{type:"doughnut",data:{labels:["Used","Free","Wasted"],datasets:[{data:[80,15,5],backgroundColor:e}],hoverOffset:10}})}(jQuery);1 !function(s){var e=s("#fastcgi-settings-button"),t=s("#fastcgi-settings-close"),i=s("#fastcgi-settings");e.on("click",function(t){s(this).toggleClass("active"),s(this).hasClass("active")?i.slideDown("fast"):i.slideUp("fast")}),t.on("click",function(t){e.removeClass("active"),i.slideUp("fast")}),s("#fly-page-cache-notice").length&&setTimeout(function(){s("#fly-page-cache-notice").fadeOut("slow")},2e3)}(jQuery); -
flywp/trunk/flywp.php
r2926998 r2927143 4 4 * Plugin URI: https://flywp.com 5 5 * Description: Helper plugin for FlyWP 6 * Version: 0.3. 16 * Version: 0.3.2 7 7 * Author: FlyWP 8 8 * Author URI: https://flywp.com/?utm_source=wporg&utm_medium=banner&utm_campaign=author-uri … … 42 42 * @var string 43 43 */ 44 public $version = '0.3. 1';44 public $version = '0.3.2'; 45 45 46 46 /** -
flywp/trunk/includes/Admin.php
r2926989 r2927143 15 15 * @var string 16 16 */ 17 const SCREEN_NAME = ' tools_page_flywp';17 const SCREEN_NAME = 'dashboard_page_flywp'; 18 18 19 19 public $fastcgi = null; … … 36 36 */ 37 37 public function register_admin_page() { 38 $hook = add_submenu_page( 39 'tools.php', 38 $hook = add_dashboard_page( 40 39 __( 'FlyWP', 'flywp' ), 41 40 __( 'FlyWP', 'flywp' ), … … 56 55 */ 57 56 public function page_url() { 58 return admin_url( ' tools.php?page=' . self::PAGE_SLUG );57 return admin_url( 'index.php?page=' . self::PAGE_SLUG ); 59 58 } 60 59 … … 87 86 $min = defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ? '' : '.min'; 88 87 89 wp_enqueue_script( 'flywp-chart', FLYWP_PLUGIN_URL . '/assets/js/chart.min.js', [], FLYWP_VERSION, true ); 90 wp_enqueue_script( 'flywp-admin-js', FLYWP_PLUGIN_URL . '/assets/js/admin' . $min . '.js', [ 'jquery', 'flywp-chart' ], FLYWP_VERSION, true ); 88 wp_enqueue_script( 'flywp-admin-js', FLYWP_PLUGIN_URL . '/assets/js/admin' . $min . '.js', [ 'jquery' ], FLYWP_VERSION, true ); 91 89 } 92 90 -
flywp/trunk/includes/Admin/Adminbar.php
r2925476 r2927143 20 20 */ 21 21 public function admin_bar_menu( $wp_admin_bar ) { 22 if ( ! current_user_can( 'manage_options' ) ) { 23 return; 24 } 25 26 $logo = '<svg viewBox="0 0 44 45" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M22 0.580017C9.85252 0.580017 0 10.4226 0 22.58C0 34.7374 9.85252 44.58 22 44.58C34.1475 44.58 44 34.7275 44 22.58C44 10.4325 34.1475 0.580017 22 0.580017ZM11.0692 27.625C10.9011 27.625 10.7329 27.625 10.5647 27.6052C11.9595 25.0234 14.6799 23.2725 17.8156 23.2725C17.9838 23.2725 18.152 23.2725 18.3201 23.2922C16.9254 25.8741 14.205 27.625 11.0692 27.625ZM32.3273 17.3867L22.5144 32.7194C21.9802 33.7086 20.4964 33.4712 20.2986 32.3633L19.3885 27.4271C19.0126 25.3894 19.8633 23.3318 21.5647 22.1448C21.7428 22.0261 21.8022 21.7886 21.6933 21.6007C21.5944 21.4127 21.3669 21.3237 21.1691 21.4029C19.2005 22.125 17.0045 21.5908 15.58 20.0476L13.2554 17.5351C12.5531 16.7734 13.0971 15.5467 14.1259 15.5467H31.3183C32.268 15.5467 32.8417 16.5953 32.3273 17.3966V17.3867Z" fill="#a7aaad"/></svg>'; 27 $style = 'background-position: 0 6px; color: #fff; background-repeat: no-repeat;background-size: 20px;float: left;height: 30px;width: 26px; background-image: url(data:image/svg+xml;base64,' . base64_encode( $logo ) . ');'; 28 22 29 $wp_admin_bar->add_node( 23 30 [ 24 31 'id' => 'flywp', 25 'title' => __( 'FlyWP', 'flywp' ),26 'href' => flywp()->admin->page_url(),32 'title' => '<div id="flywp-ab-icon" class="flywp-logo svg" style="' . $style . '"></div><span class="ab-label">' . __( 'FlyWP', 'flywp' ) . '</span>', 33 'href' => admin_url( 'index.php?page=flywp' ), 27 34 'parent' => 'top-secondary', 28 35 ] … … 30 37 31 38 if ( flywp()->fastcgi->enabled() ) { 39 if ( ! is_admin() && is_singular() ) { 40 $page_id = get_queried_object_id(); 41 $wp_admin_bar->add_node( 42 [ 43 'id' => 'flywp-cache-single', 44 'title' => __( 'Clear This Page Cache', 'flywp' ), 45 'href' => flywp()->fastcgi->purge_cache_url() . '&page_id=' . $page_id, 46 'parent' => 'flywp', 47 ] 48 ); 49 } 50 32 51 $wp_admin_bar->add_node( 33 52 [ 34 53 'id' => 'flywp-cache', 35 54 'title' => __( 'Clear Page Cache', 'flywp' ), 36 'href' => flywp()-> admin->fastcgi->purge_cache_url(),55 'href' => flywp()->fastcgi->purge_cache_url(), 37 56 'parent' => 'flywp', 38 57 ] 39 58 ); 40 59 } 60 61 if ( flywp()->opcache->enabled() ) { 62 $wp_admin_bar->add_node( 63 [ 64 'id' => 'flywp-opcache', 65 'title' => __( 'Clear OPcache', 'flywp' ), 66 'href' => flywp()->opcache->purge_cache_url(), 67 'parent' => 'flywp', 68 ] 69 ); 70 } 71 72 $wp_admin_bar->add_node( 73 [ 74 'id' => 'flywp-settings', 75 'title' => __( 'Settings', 'flywp' ), 76 'href' => admin_url( 'index.php?page=flywp' ), 77 'parent' => 'flywp', 78 ] 79 ); 41 80 } 42 81 } -
flywp/trunk/includes/Admin/Fastcgi_Cache.php
r2926989 r2927143 4 4 5 5 use FlyWP\Admin; 6 use FlyWP\Helper;7 6 8 7 class Fastcgi_Cache { … … 15 14 add_action( 'load-' . Admin::SCREEN_NAME, [ $this, 'handle_cleanup' ] ); 16 15 add_action( 'load-' . Admin::SCREEN_NAME, [ $this, 'handle_enable_disable' ] ); 17 }18 19 /**20 * FastCGI cache purge url.21 *22 * @return string23 */24 public function purge_cache_url() {25 return wp_nonce_url(26 add_query_arg(27 [ 'flywp-action' => 'purge-fastcgi-cache' ],28 flywp()->admin->page_url()29 ),30 'fly-fastcgi-purge-cache'31 );32 16 } 33 17 … … 70 54 } 71 55 72 flywp()->fastcgi->clear_cache();56 $page_id = isset( $_GET['page_id'] ) ? absint( $_GET['page_id'] ) : 0; 73 57 74 wp_safe_redirect( admin_url( 'tools.php?page=flywp&fly-notice=fastcgi-purged' ) ); 58 if ( $page_id ) { 59 flywp()->fastcgi->purge_cache_by_url( get_permalink( $page_id ) ); 60 } else { 61 flywp()->fastcgi->clear_cache(); 62 } 63 64 wp_safe_redirect( admin_url( 'index.php?page=flywp&fly-notice=fastcgi-purged' ) ); 75 65 exit; 76 66 } … … 111 101 update_option( flywp()->fastcgi::SETTINGS_KEY, $settings ); 112 102 113 wp_safe_redirect( admin_url( ' tools.php?page=flywp&fly-notice=fastcgi-saved' ) );103 wp_safe_redirect( admin_url( 'index.php?page=flywp&fly-notice=fastcgi-saved' ) ); 114 104 exit; 115 105 } … … 140 130 $notice = $type === 'enable' ? 'fastcgi-enabled' : 'fastcgi-disabled'; 141 131 142 // Toggle cache in the API143 132 $reponse = flywp()->flyapi->cache_toggle( $type ); 144 // Helper::dd( $reponse );145 133 146 134 update_option( flywp()->fastcgi::SETTINGS_KEY, $settings ); 147 135 148 wp_safe_redirect( admin_url( ' tools.php?page=flywp&fly-notice=' . $notice ) );136 wp_safe_redirect( admin_url( 'index.php?page=flywp&fly-notice=' . $notice ) ); 149 137 exit; 150 138 } -
flywp/trunk/includes/Admin/Opcache.php
r2926989 r2927143 34 34 flywp()->opcache->clear(); 35 35 36 wp_safe_redirect( admin_url( ' tools.php?page=flywp&fly-notice=opcache-purged' ) );36 wp_safe_redirect( admin_url( 'index.php?page=flywp&fly-notice=opcache-purged' ) ); 37 37 exit; 38 38 } -
flywp/trunk/includes/Fastcgi_Cache.php
r2926989 r2927143 26 26 // add_action( 'edited_term', [ $this, 'purge_taxonomy_cache' ], 10, 2 ); 27 27 // add_action( 'wp_update_nav_menu', [ $this, 'purge_home_cache' ], 10, 2 ); 28 } 29 30 /** 31 * FastCGI cache purge url. 32 * 33 * @return string 34 */ 35 public function purge_cache_url() { 36 return wp_nonce_url( 37 add_query_arg( 38 [ 'flywp-action' => 'purge-fastcgi-cache' ], 39 admin_url( 'index.php?page=flywp' ) 40 ), 41 'fly-fastcgi-purge-cache' 42 ); 28 43 } 29 44 -
flywp/trunk/includes/FlyApi.php
r2925476 r2927143 91 91 92 92 if ( is_wp_error( $response ) ) { 93 // Handle error if needed94 93 return false; 95 94 } -
flywp/trunk/includes/Frontend.php
r2910491 r2927143 12 12 public function __construct() { 13 13 new Frontend\MagicLogin(); 14 new Admin\Adminbar(); 14 15 } 15 16 } -
flywp/trunk/includes/Opcache.php
r2926989 r2927143 5 5 class Opcache { 6 6 7 /** 8 * Opcache constructor. 9 */ 7 10 public function clear() { 8 11 return opcache_reset(); 9 12 } 10 13 14 /** 15 * Check if opcache is available. 16 * 17 * @return bool 18 */ 11 19 public function has_opcache() { 12 20 return function_exists( 'opcache_get_status' ); 13 21 } 14 22 23 /** 24 * Get opcache status. 25 * 26 * @return array 27 */ 15 28 public function get_status() { 16 29 return opcache_get_status(); 17 30 } 18 31 32 /** 33 * Get opcache config. 34 * 35 * @return array 36 */ 19 37 public function get_config() { 20 38 return opcache_get_configuration(); 21 39 } 22 40 41 /** 42 * Check if opcache is enabled. 43 * 44 * @return bool 45 */ 23 46 public function enabled() { 24 47 if ( ! $this->has_opcache() ) { … … 31 54 } 32 55 56 /** 57 * Get OPcache purge URL. 58 * 59 * @return string 60 */ 33 61 public function purge_cache_url() { 34 62 return wp_nonce_url( 35 63 add_query_arg( 36 64 [ 'flywp-action' => 'purge-opcache' ], 37 flywp()->admin->page_url()65 admin_url( 'index.php?page=flywp' ), 38 66 ), 39 67 'fly-opcache-purge' -
flywp/trunk/languages/flywp.pot
r2926998 r2927143 2 2 msgid "" 3 3 msgstr "" 4 "Project-Id-Version: FlyWP 0.3. 1\n"4 "Project-Id-Version: FlyWP 0.3.2\n" 5 5 "Report-Msgid-Bugs-To: https://github.com/flywp/flywp-helper/issues\n" 6 6 "Last-Translator: [email protected]\n" … … 9 9 "Content-Type: text/plain; charset=UTF-8\n" 10 10 "Content-Transfer-Encoding: 8bit\n" 11 "POT-Creation-Date: 2023-06-16T 09:23:52+00:00\n"11 "POT-Creation-Date: 2023-06-16T15:39:14+00:00\n" 12 12 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" 13 13 "X-Generator: WP-CLI 2.7.1\n" … … 34 34 msgstr "" 35 35 36 msgid "Clear This Page Cache" 37 msgstr "" 38 36 39 msgid "Clear Page Cache" 40 msgstr "" 41 42 msgid "Clear OPcache" 43 msgstr "" 44 45 msgid "Settings" 37 46 msgstr "" 38 47 … … 41 50 42 51 msgid "You do not have permission to purge the opcache." 43 msgstr ""44 45 msgid "Settings"46 52 msgstr "" 47 53 … … 55 61 msgstr "" 56 62 63 msgid "FlyWP Dashboard" 64 msgstr "" 65 57 66 msgid "PHP OPcache has been cleared." 58 67 msgstr "" 59 68 60 msgid "PHP O pcache"69 msgid "PHP OPcache" 61 70 msgstr "" 62 71 … … 68 77 69 78 msgid "OPcache improves PHP performance by storing precompiled script bytecode in shared memory, thereby removing the need for PHP to load and parse scripts on each request." 79 msgstr "" 80 81 msgid "Hit Rate" 82 msgstr "" 83 84 msgid "Cached Scripts" 85 msgstr "" 86 87 msgid "Memory" 88 msgstr "" 89 90 msgid "Keys" 91 msgstr "" 92 93 msgid "Engine" 70 94 msgstr "" 71 95 -
flywp/trunk/readme.txt
r2926998 r2927143 5 5 Tested up to: 6.2 6 6 Requires PHP: 7.4 7 Stable tag: 0.3. 17 Stable tag: 0.3.2 8 8 Requires PHP: 7.1 or higher 9 9 License: GPLv2 or later … … 52 52 53 53 1. FlyWP settings page. 54 2. Cloud server management dashboard.55 3. Caching settings and controls.56 54 57 55 == Changelog == 56 57 = v0.3.2 (16 June, 2023) = 58 59 * **Fix:** Removed unused Chart.js library. 60 * **Improved:** The admin bar is improved with logo and a settings page. Now it shows on the frontend too, with singular resource clear link. 61 * **Improved:** The settings page has moved to the Dashboard menu. It's responsive now and has a logo. 58 62 59 63 = v0.3.1 (16 June, 2023) = -
flywp/trunk/vendor/autoload.php
r2926998 r2927143 23 23 require_once __DIR__ . '/composer/autoload_real.php'; 24 24 25 return ComposerAutoloaderInit cc227957e42c2818fe0f5977f8d16a8d::getLoader();25 return ComposerAutoloaderInitedc10cb8386cda1f9e804abee7ed7720::getLoader(); -
flywp/trunk/vendor/composer/autoload_real.php
r2926998 r2927143 3 3 // autoload_real.php @generated by Composer 4 4 5 class ComposerAutoloaderInit cc227957e42c2818fe0f5977f8d16a8d5 class ComposerAutoloaderInitedc10cb8386cda1f9e804abee7ed7720 6 6 { 7 7 private static $loader; … … 23 23 } 24 24 25 spl_autoload_register(array('ComposerAutoloaderInit cc227957e42c2818fe0f5977f8d16a8d', 'loadClassLoader'), true, true);25 spl_autoload_register(array('ComposerAutoloaderInitedc10cb8386cda1f9e804abee7ed7720', 'loadClassLoader'), true, true); 26 26 self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__)); 27 spl_autoload_unregister(array('ComposerAutoloaderInit cc227957e42c2818fe0f5977f8d16a8d', 'loadClassLoader'));27 spl_autoload_unregister(array('ComposerAutoloaderInitedc10cb8386cda1f9e804abee7ed7720', 'loadClassLoader')); 28 28 29 29 require __DIR__ . '/autoload_static.php'; 30 call_user_func(\Composer\Autoload\ComposerStaticInit cc227957e42c2818fe0f5977f8d16a8d::getInitializer($loader));30 call_user_func(\Composer\Autoload\ComposerStaticInitedc10cb8386cda1f9e804abee7ed7720::getInitializer($loader)); 31 31 32 32 $loader->register(true); -
flywp/trunk/vendor/composer/autoload_static.php
r2926998 r2927143 5 5 namespace Composer\Autoload; 6 6 7 class ComposerStaticInit cc227957e42c2818fe0f5977f8d16a8d7 class ComposerStaticInitedc10cb8386cda1f9e804abee7ed7720 8 8 { 9 9 public static $prefixLengthsPsr4 = array ( … … 57 57 { 58 58 return \Closure::bind(function () use ($loader) { 59 $loader->prefixLengthsPsr4 = ComposerStaticInit cc227957e42c2818fe0f5977f8d16a8d::$prefixLengthsPsr4;60 $loader->prefixDirsPsr4 = ComposerStaticInit cc227957e42c2818fe0f5977f8d16a8d::$prefixDirsPsr4;61 $loader->classMap = ComposerStaticInit cc227957e42c2818fe0f5977f8d16a8d::$classMap;59 $loader->prefixLengthsPsr4 = ComposerStaticInitedc10cb8386cda1f9e804abee7ed7720::$prefixLengthsPsr4; 60 $loader->prefixDirsPsr4 = ComposerStaticInitedc10cb8386cda1f9e804abee7ed7720::$prefixDirsPsr4; 61 $loader->classMap = ComposerStaticInitedc10cb8386cda1f9e804abee7ed7720::$classMap; 62 62 63 63 }, null, ClassLoader::class); -
flywp/trunk/vendor/composer/installed.php
r2926998 r2927143 2 2 'root' => array( 3 3 'name' => 'flywp/flywp', 4 'pretty_version' => '0.3. 1',5 'version' => '0.3. 1.0',4 'pretty_version' => '0.3.2', 5 'version' => '0.3.2.0', 6 6 'reference' => NULL, 7 7 'type' => 'wordpress-plugin', … … 12 12 'versions' => array( 13 13 'flywp/flywp' => array( 14 'pretty_version' => '0.3. 1',15 'version' => '0.3. 1.0',14 'pretty_version' => '0.3.2', 15 'version' => '0.3.2.0', 16 16 'reference' => NULL, 17 17 'type' => 'wordpress-plugin', -
flywp/trunk/views/admin.php
r2926989 r2927143 1 1 <div class="flywp-settings" id="flywp-settings"> 2 2 <div class="fw-mb-8 fw-bg-white fw-border-b fw-border-solid fw-border-gray-200"> 3 <div class="fw-max-w-xl fw-mx-auto"> 4 <div class="fw-flex fw-py-4 fw-items-center fw-justify-between"> 5 <h1 class="fw-text-2xl fw-font-semibold fw-flex-1">FlyWP</h1> 3 <div class="fw-max-w-xl fw-mx-auto fw-px-4 sm:fw-px-0"> 4 <div class="fw-flex fw-py-2 fw-items-center fw-justify-between"> 5 <h1 class="fw-text-2xl fw-font-semibold fw-flex-1"> 6 <img src="<?php echo esc_url( FLYWP_PLUGIN_URL . 'assets/images/flywp-logo.svg' ); ?>" alt="FlyWP" class="fw-h-11 fw-mr-2 fw-inline-block"> 7 </h1> 6 8 7 9 <div class=""> 8 <a href="https://app.flywp.com" target="_blank" class="button button-secondary"><span class="dashicons dashicons-external fw-mt-1"></span> FlyWP Dashboard</a>10 <a href="https://app.flywp.com" target="_blank" class="button button-secondary"><span class="dashicons dashicons-external fw-mt-1"></span> <?php esc_html_e( 'FlyWP Dashboard', 'flywp' ); ?></a> 9 11 </div> 10 12 </div> … … 12 14 </div> 13 15 14 <div class="fw-max-w-xl fw-mx-auto ">16 <div class="fw-max-w-xl fw-mx-auto fw-px-4 sm:fw-px-0"> 15 17 <?php require __DIR__ . '/page-cache.php'; ?> 16 18 <?php require __DIR__ . '/op-cache.php'; ?> -
flywp/trunk/views/op-cache.php
r2926989 r2927143 18 18 <div class="fw-flex fw-px-4 fw-py-4 fw-fw-sm:p-6 fw-items-center fw-justify-between fw-border-b fw-border-gray-200"> 19 19 <h3 class="fw-text-lg fw-font-semibold fw-leading-6 fw-text-gray-900 fw-m-0"> 20 <?php esc_html_e( 'PHP O pcache', 'flywp' ); ?>20 <?php esc_html_e( 'PHP OPcache', 'flywp' ); ?> 21 21 </h3> 22 22 … … 44 44 <p class="fw-mt-0"><?php esc_html_e( 'OPcache improves PHP performance by storing precompiled script bytecode in shared memory, thereby removing the need for PHP to load and parse scripts on each request.', 'flywp' ); ?></p> 45 45 46 47 <div class="fw-flex fw-w-full fw-mb-4 fw-gap-3 fw-items-center">48 <div class="fw-w-2/3">49 <dl class="fw-m-0 fw-mt-2">50 <div class="fw-flex fw-w-full">51 <dt class="fw-font-medium fw-text-gray-900 sm:fw-w-32 sm:fw-flex-none sm:fw-pr-6">Hit Rate</dt>52 <dd><?php echo number_format( $status['opcache_statistics']['opcache_hit_rate'], 2 ) . '%'; ?></dd>53 </div>46 <?php if ( flywp()->opcache->enabled() ) { ?> 47 <div class="md:fw-flex fw-w-full fw-mb-4 fw-gap-3 fw-items-center"> 48 <div class="sm:fw-w-2/3 fw-mb-6 sm:fw-mb-0"> 49 <dl class="fw-m-0 fw-mt-2"> 50 <div class="fw-flex fw-justify-between sm:fw-justify-normal"> 51 <dt class="fw-font-medium fw-text-gray-900 sm:fw-w-32 sm:fw-flex-none sm:fw-pr-6"><?php esc_html_e( 'Hit Rate', 'flywp' ); ?></dt> 52 <dd><?php echo number_format( $status['opcache_statistics']['opcache_hit_rate'], 2 ) . '%'; ?></dd> 53 </div> 54 54 55 <div class="fw-flex">56 <dt class="fw-font-medium fw-text-gray-900 sm:fw-w-32 sm:fw-pr-6">Cached Scripts</dt>57 <dd><?php echo $status['opcache_statistics']['num_cached_scripts']; ?></dd>58 </div>55 <div class="fw-flex fw-justify-between sm:fw-justify-normal"> 56 <dt class="fw-font-medium fw-text-gray-900 sm:fw-w-32 sm:fw-pr-6"><?php esc_html_e( 'Cached Scripts', 'flywp' ); ?></dt> 57 <dd><?php echo $status['opcache_statistics']['num_cached_scripts']; ?></dd> 58 </div> 59 59 60 <div class="fw-flex">61 <dt class="fw-font-medium fw-text-gray-900 sm:fw-w-32 sm:fw-pr-6">Memory</dt>62 <dd><?php echo sprintf( '%s of %s', size_format( $status['memory_usage']['used_memory'] ), size_format( $config['directives']['opcache.memory_consumption'] ) ); ?></dd>63 </div>60 <div class="fw-flex fw-justify-between sm:fw-justify-normal"> 61 <dt class="fw-font-medium fw-text-gray-900 sm:fw-w-32 sm:fw-pr-6"><?php esc_html_e( 'Memory', 'flywp' ); ?></dt> 62 <dd><?php echo sprintf( '%s of %s', size_format( $status['memory_usage']['used_memory'] ), size_format( $config['directives']['opcache.memory_consumption'] ) ); ?></dd> 63 </div> 64 64 65 <div class="fw-flex">66 <dt class="fw-font-medium fw-text-gray-900 sm:fw-w-32 sm:fw-pr-6">Keys</dt>67 <dd><?php echo sprintf( '%d of %d', $status['opcache_statistics']['num_cached_keys'], $status['opcache_statistics']['max_cached_keys'] ); ?></dd>68 </div>65 <div class="fw-flex fw-justify-between sm:fw-justify-normal"> 66 <dt class="fw-font-medium fw-text-gray-900 sm:fw-w-32 sm:fw-pr-6"><?php esc_html_e( 'Keys', 'flywp' ); ?></dt> 67 <dd><?php echo sprintf( '%d of %d', $status['opcache_statistics']['num_cached_keys'], $status['opcache_statistics']['max_cached_keys'] ); ?></dd> 68 </div> 69 69 70 <div class="fw-flex">71 <dt class="fw-font-medium fw-text-gray-900 sm:fw-w-32 sm:fw-pr-6">Engine</dt>72 <dd><?php echo sprintf( '%s (%s)', $config['version']['opcache_product_name'], $config['version']['version'] ); ?></dd>73 </div>74 </dl>75 </div>70 <div class="fw-flex fw-justify-between sm:fw-justify-normal"> 71 <dt class="fw-font-medium fw-text-gray-900 sm:fw-w-32 sm:fw-pr-6"><?php esc_html_e( 'Engine', 'flywp' ); ?></dt> 72 <dd><?php echo sprintf( '%s (%s)', $config['version']['opcache_product_name'], $config['version']['version'] ); ?></dd> 73 </div> 74 </dl> 75 </div> 76 76 77 <?php if ( flywp()->opcache->enabled() ) { ?> 78 <div class="fw-w-1/3"> 77 <div class="sm:fw-w-1/3 fw-text-center sm:fw-text-right"> 79 78 <a href="<?php echo esc_url( flywp()->opcache->purge_cache_url() ); ?>" class="button button-primary button-hero"><?php esc_html_e( 'Clear Cache', 'flywp' ); ?></a> 80 79 </div> 81 <?php } ?> 82 </div> 83 84 80 </div> 81 <?php } ?> 85 82 </div> 86 83 </div> -
flywp/trunk/views/page-cache.php
r2926989 r2927143 42 42 <?php } ?> 43 43 44 <div class="fw-mt-2 fw-px-4 fw-py-4 fw-fw-sm:p-6 fw-text-sm fw-text-gray-500 fw-flex">45 <div class=" fw-w-2/3">44 <div class="fw-mt-2 fw-px-4 fw-py-4 fw-fw-sm:p-6 fw-text-sm fw-text-gray-500 md:fw-flex"> 45 <div class="md:fw-w-2/3"> 46 46 <p class="fw-mt-0"><?php esc_html_e( 'Nginx FastCGI Cache is a very fast page caching system that boosts up your website page load speed. It\'s recommended to enable the page cache.', 'flywp' ); ?></p> 47 47 </div> 48 48 49 49 <?php if ( flywp()->fastcgi->enabled() ) { ?> 50 <div class=" fw-w-1/3fw-text-right">51 <a href="<?php echo esc_url( $this->fastcgi->purge_cache_url() ); ?>" class="button button-primary button-hero"><?php esc_html_e( 'Clear Cache', 'flywp' ); ?></a>50 <div class="md:fw-w-1/3 fw-text-center md:fw-text-right"> 51 <a href="<?php echo esc_url( flywp()->fastcgi->purge_cache_url() ); ?>" class="button button-primary button-hero"><?php esc_html_e( 'Clear Cache', 'flywp' ); ?></a> 52 52 </div> 53 53 <?php } ?>
Note: See TracChangeset
for help on using the changeset viewer.