Dan

Forum Replies Created

Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • in reply to: tribe_events_update_meta Triggers Twice #40833
    Dan
    Participant

    Casey. Definitely the frontend, not sure if it’s happening on the backend. I noticed that the two $false arrays were different though and that the second one held a few more keys (http://pastebin.com/nnUwP2DZ). For the mean time I am doing a quick fix by only targeting the second action based on a conditional for a key in the second array that’s not in the first.

    in reply to: Get Event ID On Submit From Frontend #33164
    Dan
    Participant

    Casey,
    All seems to be working fine so far. It may have been a result of updating to the most recent versions that fixed everything. Thanks again for your help.

    in reply to: Get Event ID On Submit From Frontend #33159
    Dan
    Participant

    Casey. Not sure what has changed… I must have moved something around, but it seems to be working. I plan to do more testing tonight. I will report back if I have any more errors or can put this to rest.

    Thanks so much for your help and sticking with me.

    in reply to: Get Event ID On Submit From Frontend #33157
    Dan
    Participant

    No. triggered in backend and in frontend only when adding a new event. When updating an event on the frontend, it’s not being triggered.

    Thanks

    in reply to: Get Event ID On Submit From Frontend #33155
    Dan
    Participant

    Casey,
    When adding a new event from the front end, the tribe_events_update_meta action is triggered.

    in reply to: Get Event ID On Submit From Frontend #33153
    Dan
    Participant

    Casey,
    That is correct. I am not able to see the output of var_dump on the frontend. I have updated to 2.0.11 and 1.0.5. In the backend, I see the var_dump and exit() triggered.

    From the source code, it looks like the only problem could be with the file tribe-event-api.class.php. In the updateEvent function saveEventMeta is only triggered if wp_update_post($args) returns true…
    Thanks.

    in reply to: Get Event ID On Submit From Frontend #33115
    Dan
    Participant

    Casey,
    Unfortunately, it doesn’t appear that the tribe_events_update_meta hook is triggered when events are saved via community events. The meta is saved when on the backend, however.

    add_action( ‘tribe_events_update_meta’, ‘pcs_save_trash_meta’, 10, 1 );
    function pcs_save_trash_meta($post_id) {
    global $post;
    $post_id = (int) $post_id;
    var_dump($post_id); exit();
    }

    With the above code in my functions.php file, the “Event submitted.” page shows up after submission with no exit() command called. The database also has not been updated.

    in reply to: Get Event ID On Submit From Frontend #33087
    Dan
    Participant

    Casey,
    So I looked into it. Will this action also trigger when saving an event in the backend? Currently I am using ‘save_post’ action to trigger my function to save the post meta in the backend. Can I remove that hook and still have my function triggered from tribe_events_update_meta?
    Thank!

    in reply to: Get Event ID On Submit From Frontend #33025
    Dan
    Participant

    Casey,
    Thanks for your quick responses. I was recently pulled onto another project and haven’t had a chance to investigate your suggestion. I will let you know how it goes when I can try it out.

    Thanks!

    in reply to: Rain Date for Events #30030
    Dan
    Participant

    Barry. Thanks for the quick reply. It’s true, additional field feature could work, but then it wouldn’t have datepicker functionality.

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