• Resolved shivnc77

    (@shivnc77)


    Hello

    I’m using WPEngine, WordPress and the Advanced Custom Fields object, and Object Sync for SF. I’ve been successful setting up the Object Sync – authorizing etc. I successfully created the field group and fields in ACF. I cannot, however, for the life of me, figure out how to create a custom object in WordPress. So, I can find the ACF fields and map my SF fields to them by looking in Page object, but, we’re going to be using a custom post template, and we’re able to bring in those fields, but, posts aren’t being created from the template after syncing, and I think it’s because we need the ACF fields to be in a custom object. Right? Bear with me, I’m a noob! Thanks!

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Jonathan Stegall

    (@jonathanstegall)

    I’d preface this by saying that I’m not super familiar with ACF. I’ve tried to add support for it whenever possible, but it is still likely that some features of ACF don’t work with this plugin.

    Aside from that, a few questions:

    1. If you’re creating a custom post type, you should be able to find it in the WordPress Object field. If you don’t see it in that list, make sure there’s at least one record of that object type in WordPress, and clear the plugin cache if you didn’t have one before.
    2. If the plugin simply doesn’t recognize your custom object, it means you’re likely deviating a lot from the WordPress core methods of creating custom post types, and it’s possible that this plugin won’t work without a lot of custom code. We do have a lot of developer hooks for this purpose, but we don’t really provide support for them beyond documentation. See the hook to add additional WordPress post types, for example.
    3. If you can find your ACF fields on the Page object, you might be adding them to the wrong object? But similarly to the note in #1, if you have a custom post object and WordPress doesn’t have at least one value for each field, the plugin won’t recognize it (because WordPress doesn’t store a list of custom fields we can only retrieve the fields that have values). Add some values and clear the plugin cache if you think that might be relevant.

    If none of these helps, like I mentioned, you might be using more custom methods than we can support by default.

    Thread Starter shivnc77

    (@shivnc77)

    thank you!

    I figured it out and am making great progress. I stopped using ACF and am just using regular WordPress custom fields.

    Now my problem is that I can’t seem to map an image field of type URL to an image in WP. Any suggestions?

    Plugin Author Jonathan Stegall

    (@jonathanstegall)

    Well, images in WordPress take more fields than just a URL, so you may have trouble with this. If you’re only doing a URL that points to an image that is uploaded somewhere else, you can just map it to a text field and display it with img src=”url” or however you might want to display it. But if you’re trying to upload the image into the WordPress media library it takes more fields. It’s doable, but you’d have to check all of the fields that get stored in the post and postmeta tables for a library item and map all of them.

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

The topic ‘Cannot Create WP Object’ is closed to new replies.