manifest / performance / acf-getallobjects
ACF Get All Objects
get_field has cost in front end! it means when you perform this function it calls multiple time queries as you store data in your backend. in simple words if you had 1000 text box in your acf option back-end and you call acf get_field in front-end it will call mysql query 1000 times and if you want use acf and care about your performance you will need to use this plugin or other approciate approche.
by dariushvesal · github.com/devlifex/acf-getallobjects · website
★ 32stars
5forks
Install
No release zip yet. The repository archive installs, but the folder name will carry the branch suffix and updates will not flow:
wp plugin install https://github.com/devlifex/acf-getallobjects/archive/refs/heads/master.zipFrom the readme
ACF getallobjects
FOR DEVELOPERS Only!
getfield has cost in front end! it means when you perform this function it calls multiple time queries as you store data in your backend. in simple words if you had 1000 text box in your acf option back-end and you call acf getfield in front-end it will call mysql query 1000 times and if you want use acf and care about your performance you will need to use this plugin or other approciate approche.
Before use this plugin
After use this plugin
How is work?
After save acf in backend this plugin create record in Database(wpoptions) with this pattern (acfAllObjects+postid) as key
and put all your fields data as whole object in value. then you instead of
you can use
How to Use?
1) Clone or Download in your plugins directory
2) Activate plugin from wp-admin
3) Go to your acf post type (option or custom post type etc...) and save again (for create acfAllObjects record)
4) Go to your theme file and replace your current code with this structure