0

I have a custom post type that in admin area has a select custom meta box with 12.000+ options. So, in some cases, WordPress show an error message like memory exhausted.

Which could be a good troubleshooting to do?

Thanks!

2
  • 1
    Don’t know what you expect to find by troubleshooting. 12000 options, presumably loaded from a database, is just too much to load at once. You need to find an alternative UI for loading these options. Commented May 29, 2018 at 3:24
  • Thanks for your comment. Sorry if I didn't explain it clearly. I asking for suggestions to find those alternatives that you talk Commented May 29, 2018 at 3:31

1 Answer 1

0

I think your best shot would be to use a javascript-enhanced selectbox like select2 and an ajax-action to search for options. Right now, i don't have the time to write actual pseudo-code for you, but i guess this link should give you the direction: https://select2.org/data-sources/ajax

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.