Archived topic
Caching the menu
6 replies · Started by Marc on May 1, 2019
Hi Tom,
It would seem that the menu is generated upon each page load. I would like to use transients to store the menu in cache. How would I go about that? Or is that a feature you would like to add?
The more complex my menu gets, the slower my site gets. But rarely do I change the menu ...
Cheers,
Marc
Hi there,
This is a really cool solution that might be worth trying: https://bjornjohansen.no/wordpress-menu-cache
Let me know :)
Yes, that's what I mean! Alas, I get errors I can't fix (probably due to the dashicons). I'll scale down the number of items in my menu instead.
Thanks anyway!
Marc
No problem!
Reading up on transients and speeding up menus.
1. Does GP allready do this, or has its prefered methods?
2. Found a really neat (nice and simple solution seting transients here and unvalidating on menu update here )
Also a short article here --> https://felix-arntz.me/blog/transients-speed-up-wordpress-theme/
Would this work with GP menu in your opinion?
Menu does not update often so it seems to me like a perfect candidate for such a thing.
Thanks
I've never tried it, but if it's built to work with the WP menu system it will work with GP. We don't make any core modifications to the core menu system.
Cool, I'll give it a try. :) If I can reduce the number of queries on basically every page ... I am interested. :)