save_event hook

This topic contains 3 replies, has 2 voices, and was last updated by  Craig Haller 8 months, 1 week ago.

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #43008

    I have an input on my FES called “Sponsor.” It may be left blank. I also am importing some feeds and they don’t have that field.
    I am looking to use a hook to check the field and edit it if necessary. I am using the save (I tried create as well) with this:

    update_post_meta( $post_id, 'bdn_event_sponsor', 'abcd' );
    

    This appears to create the meta before the event is written into the post since I end up with two ‘bdn_envent_sponsor’ keys. I assume the FES made one and I made one.
    Does the save_event hook fire after the post is created but before the form data is put in the post?
    Is there a hook right after the post is created and saved?
    Thanks

    Craig Haller
    #43009

    I am using eventorganizer_save_event btw.

    Craig Haller
    #43062

    eventorganiser_save_event triggers after the event has been created, but before FES has inserted all the metadata.

    There is a filter eventorganiser_fes_submit_event which allows you to filter the event before its created, it passes the form object as the second argument.

    Stephen Harris
    #43063

    Perfect! Thank you.
    -C

    Craig Haller
Viewing 4 posts - 1 through 4 (of 4 total)
To enable me to focus on Pro customers, only users who have a valid license for the Pro add-on may post new topics or replies in this forum. If you have a valid license, please log-in or register an account using the e-mail address you purchased the license with. If you don't you can purchase one here. Or there's always the WordPress repository forum.