Support

Account

Home Forums Backend Issues (wp-admin) Is it possible to add another query to ACF itself?

Helping

Is it possible to add another query to ACF itself?

  • Hi guys,

    I have an issue that concerns not being able to import data into repeater fields because there is no external plugin that can do this.

    First things first I have a second non WP database with data I want to go into the WP database as well as a WP instance with ACF as plugin+repeater fields addon. I thought I could make ACF select the data with a wpdb instance to connect to the second database to than use ACF’s backend to try and make it insert data or as ACF does it save_post the data into the WP database?

    Am I on the right track of inserting the data into the WP database like this or am I doing this wrongly? PLease advice me on my road to create some kind of importer or explaining me how ACF inserts data into WP.

    Thanks in advance!

  • This is a pretty old question, but for others looking for a way to import data into ACF.

    First there are now import plugins that will do this. One of them can be found here http://www.wpallimport.com/

    If you want to do this yourself then you will need to learn how the names of fields and rows are created in the DB. Also, each entry in the DB is made up of 2 entries. The first is your data and the second is the field key information. Information on the DB fields is covered here https://www.advancedcustomfields.com/resources/update_field/.

    You might also try using ACF functions update_field, update_row, and add_row https://www.advancedcustomfields.com/resources/update_row/ https://www.advancedcustomfields.com/resources/add_row/, but more than likely attempting to import using these functions, if you have a lot of data to import, will time out.

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

The topic ‘Is it possible to add another query to ACF itself?’ is closed to new replies.