Tagged: Minification
-
AuthorPosts
-
October 24, 2018 at 12:39 am #1025703
Hi – I just updated to Enfold 4.5 and have a question. I disabled my minification plugin, and enabled the theme performance settings for css and js merge and compress. I saved the options, cleared cache and ran the speed test on the home page (www.thomashenthorne.com) to see how page speed is looking. The first item on GT METRIX speed tool for my site says that js minification is not enabled.
When I look at the code for the pages, they do not appear to be minified.
What am I doing wrong?
Thanks,
RobOctober 24, 2018 at 11:09 pm #1026151Hey goldengate415,
Please post us your login credentials (in the “private data” field), so we can take a look at your backend.
- Install and activate ” Temporary Login Without Password “.
- Go to ” Users > Temporary Logins ” on the left-side menu.
- Click ” Create New “.
- Add the email address for the account ( you can use (Email address hidden if logged out) ), as well as the ” Role ” making that the highest possible and the expiry about four days
( do be sure that we have enough time to debug ). - Click ” Submit “.
- You’ll now have a temporary account. Please provide us here in the private section the URL, so we can login and help you out.
When your issue is fixed, you can always remove the plugin!
If you prefer to not use the plugin, you can manually create a admin user and post the login credentials in the “private data” field.Best regards,
BasilisOctober 24, 2018 at 11:23 pm #1026152In private content, thanks!
October 27, 2018 at 10:38 pm #1027212It appears an Enfold mod logged in using the credentials a day or two ago but I don’t see an update on this thread…?
October 29, 2018 at 3:52 am #1027363Hi,
Sorry about that. I logged in last Friday and saw that the merge is working, but I couldn’t figure out why some of the scripts and stylesheets from third party extensions are not included in the merged file. (see private field)
Please disable the theme’s compression and install a third party minification plugin such as Autoptimize or BWP.
Best regards,
IsmaelOctober 29, 2018 at 4:24 am #1027367Hi Ismael,
Is this something that you and the Enfold team might continue to work on, since if it’s affecting me it’s probably affecting others?
Many thanks,
RobOctober 30, 2018 at 5:53 am #1027857Hi,
You can try this filter in the functions.php file but I’m not sure if this is going to work because it’s not working on my installation. It’s supposed to include every scripts and stylesheets in the compression but I don’t see the distinction between the “all” value and the default “avia-module” when I review the compression script.
add_filter('avf_merge_assets', function() { return array('css' => 'all', 'js' => 'all'); });
Please post the FTP details in the private field.
Best regards,
IsmaelOctober 30, 2018 at 6:31 am #1027880Thanks Ismael…. in private content…..
November 2, 2018 at 5:41 am #1029004Hi,
It turned out that the theme minifies tested plugins or plugins that were included in this list.
//all plugins that start with the name "avia" are considered tested $tested_plugins = apply_filters( 'avf_tested_plugin_list' , array( 'hello.php', 'akismet/akismet.php', 'layerslider/layerslider.php', 'tiny-compress-images/tiny-compress-images.php', 'woocommerce/woocommerce.php', 'shortpixel-image-optimiser/wp-shortpixel.php', 'optimus/optimus.php', 'wp-super-cache/wp-cache.php', 'comet-cache/comet-cache.php', 'comet-cache-pro/comet-cache-pro.php', 'duplicate-post/duplicate-post.php', 'wordpress-importer/wordpress-importer.php', 'wordpress-beta-tester/wp-beta-tester.php', 'worker/init.php', //managewp 'really-simple-ssl/rlrsssl-really-simple-ssl.php', 'bbpress/bbpress.php', ));
You can use the “avf_tested_plugin_list” filter to add more plugins in that list. You can only include plugins that load their resources directly from the plugin directory, not from external sites.
add_filter( 'avf_tested_plugin_list', 'avf_tested_plugin_list_mod', 10, 1 ); function avf_tested_plugin_list_mod($plugins) { $plugins[] = 'your-plugin/your-plugin.php'; $plugins[] = 'another-plugin/another-plugin.php'; return $plugins; }
Best regards,
IsmaelNovember 6, 2018 at 7:42 pm #1030537Hi Ismael,
I’m not a coder, though I am flattered you think I can do the above… the only filter I use is a coffee filter! haha
It seems like if Enfold is going to claim minification, the theme should minify all plugins, not just a list. And we should not need to customize code for the minification option to work since minification plugins don’t require a list of plugins.
Where do we go from here? :)
November 8, 2018 at 10:16 pm #1031410Hi,
We understand that but you see the issue is that we can also not test every possible plugin – and to avoid issues we have build it like that! :)
( BTW – I have enjoyed the filter joke a lot )Best regards,
BasilisNovember 8, 2018 at 11:14 pm #1031441haha yes I totally get it… but when i installed minification plugins they work for all plugins, not just certain ones….
Maybe something to flag with coders for future development?
Enjoy your coffee! :)
November 9, 2018 at 2:05 am #1031474Wow, so glad I came across this thread, thanks for raising it @goldengate415
Is the advice/easiest option then to ignore Enfold minification options if you have plugins installed other than those above (such as the popular highly recommended The Events Calendar) and use something like autoptimize?It’s tea drinking time here – no filters required ;)
H
November 9, 2018 at 12:42 pm #1031630It’s all Greek to me – Should we add all the plugins we are currently using to this list? And where is this “list”?
November 11, 2018 at 8:23 pm #1032303Hi Gitte,
The list is in the /includes/helper-assets.php file and you can use the filter specified by Ismael to add the plugin you need, but results may vary.
Best regards,
Victoria -
AuthorPosts
- You must be logged in to reply to this topic.