Support

Account

Home Forums Backend Issues (wp-admin) Google maps field in Repeater too slow

Solving

Google maps field in Repeater too slow

  • Not sure if this was more oriented towards the ACF PRO category but it’s definitely backend related:

    I have a custom options page that holds a repeater field where a Google maps field is present. Currently holds ~100 entries. Problem is that every time now someone tries to open the page there are over 1500 requests, about 90% of those towards the Google API.

    That leads to a wait time of ~70 seconds to be able to use the page and dev tools logs 17.7 minute for the load to finish.

    Anyone has any ideas how to make this work? I was thinking that having the google maps collapsed somehow for each field and only to load each map per user action ( click to reveal ) for editing would make things way way faster.

    Using latest versions for both WP & ACF (PRO).

    To add to this: After entry 111, I cannot save the location of the last entered field nor add any new ones. Not sure if this is related to the loading/requests problem.

  • Hi @netfreak

    I understand why you have issues! loading a hundred maps on a single page is going to be slow and really not something one want to encounter..

    I think that rather than this being an issue with ACF it’s an issue of architecture. Do you really need all of these at an options page? It would seem a better solution is to create a custom post type and place a single map for each post. Then you will only load one map for each post in admin. There’s also the advantages of being able to utilize wp_query for either simple queries or to fetch only specific maps easily. You’ll also get a much more approachable admin interface with search capabilities, ability to sort by date etc. etc.

    My suggestion is thus to not try to patch up a leaky ship but change it completely instead.

  • There is a use case for hundreds of map points on a page. The problem is on the front-end the information is rendered with one map and multiple pins on it. In the back-end, it shows hundreds of maps, each with one pin. This isn’t a problem of the use case, it’s the UI that is overloading.

Viewing 3 posts - 1 through 3 (of 3 total)

The topic ‘Google maps field in Repeater too slow’ is closed to new replies.