Overwrite Tribe__Events__Linked_Posts

Home Forums Welcome! Pre-Sales Questions Overwrite Tribe__Events__Linked_Posts

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #1610364
    Ram Nepal
    Guest

    Hi There,
    How do we can override Tribe__Events__Linked_Posts class? I want to add some code under public function unlink_post( $target_post_id, $subject_post_id ) . .

    Please help me out.
    Regards

    #1612459
    Andras
    Keymaster

    Hi Ram,

    We are unfortunately unable to provide support through our Pre-Sales forum channel, but you can head over to The Events Calendar WordPress.org support forums for assistance and answers.

    If you have a PRO license, you can log into your account and get assistance through the PRO forums. If you need to reset your password, you can do so here. This will send an email to the account used when you initially registered for the support forums.

    To get you started…

    I believe there is no way to override that class.

    But you could hook into the following action:

    [code language=”php”]do_action( ‘tribe_events_unlink_post’, $target_post_id, $subject_post_id );[/code]

    So you would need to add something like this in your functions.php file:

    [code language=”php”]
    add_action( ‘tribe_events_unlink_post’, ‘my_action’ );

    function my_action( $target_post_id, $subject_post_id ) {
    //do stuff here
    }
    [/code]

    Cheers,
    Andras

Viewing 2 posts - 1 through 2 (of 2 total)
  • The topic ‘Overwrite Tribe__Events__Linked_Posts’ is closed to new replies.