Forum Replies Created

Viewing 2 replies - 1 through 2 (of 2 total)
  • I found that the keys changed depending on the action taking place. Is there a better way for me to check this?

    `function wpt_venue_dropdown($fields, $event_id){

    if( $fields[0][‘id’] === ‘wp_theatre_prod’ ){
    $fields[3][‘edit’] = array(“callback” => ‘editVenues’ );
    $fields[3][‘save’] = array(“callback” => ‘saveVenues’ );
    } else {
    $fields[2][‘edit’] = array(“callback” => ‘editVenues’ );
    $fields[2][‘save’] = array(“callback” => ‘saveVenues’ );
    }

    return $fields;

    }

    add_filter(‘wpt/event_editor/fields’,’wpt_venue_dropdown’,10,3);’

    Jeroen, Could you help out a little bit with the filter. I know I need to at least do this, but not sure what to do from there.

    `function wpt_venue_dropdown($fields, $event_id){

    return $fields;

    }

    add_filter(‘wpt/event_editor/fields’,’wpt_venue_dropdown’,10,3);

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