Home › Forums › Ticket Products › Eventbrite Tickets › Missing argument 2 for Event_Tickets_PRO tribe_get_cost()
- This topic has 3 replies, 2 voices, and was last updated 13 years ago by
Kelly.
-
AuthorPosts
-
October 15, 2013 at 9:47 am #71105
digitallifesciences
ParticipantI installed the EB Tickets plugin today and I have warnings appearing on pages.
It would appear it’s trying to get the cost, but the events are free, so I’m wondering if there is a function missing a default value or something?
This ticket was opened by another user and the issue was not resolved because the Tribe developer was not able to recreate the issue – I would just like to point out that a simple google search of the discussion title will reveal several instances of this.
October 15, 2013 at 9:55 am #71109digitallifesciences
ParticipantThis is the function causing the issue. Documentation suggests postId should be optional – it’s not(lib/tribe-eventbrite.class.php on line 231).
/**
* Event Cost
*
* If EventBrite plugin is active
* – If the event is registered in Eventbrite, and has one ticket. Return the cost of that ticket.
* – If the event is registered in Eventbrite, and there are many tickets, return “Varies”
* – If the event is not registered in Eventbrite, and there is meta, return that.
* – If the event is not registered in Eventbrite, and there is no meta, return “”
*
* @param null|int $postId (optional)
* @param bool $withCurrencySymbol Include the currency symbol
* @return string Cost of the event.
*/
public function tribe_get_cost( $cost, $postID, $withCurrencySymbol ){
if ( class_exists( ‘Eventbrite_for_TribeEvents’ ) ) {
global $spEventBrite;
$returned = $spEventBrite->tribe_get_cost( $postId );
if ( $returned ) {
$cost = esc_html( $returned );
}
}
return apply_filters( ‘tribe_eb_event_get_cost’, $cost, $postID, $withCurrencySymbol );
}October 16, 2013 at 7:52 am #71257Kelly
ParticipantHi, digitallifesciences. I’m sorry to hear that you’re having an issue with errors coming up.
Would you mind posting the error so that we could look into it? Also, it would be helpful to be able to see the site in question. π
Thanks!
October 30, 2013 at 3:08 pm #73874Kelly
ParticipantHi, digitallifesciences. Since itβs been a couple of weeks, Iβm going to close this thread. I hope that you were able to resolve it on your own. If not, please start a new thread.
Thanks for being part of the Modern Tribe Community! π
-
AuthorPosts
- The topic ‘Missing argument 2 for Event_Tickets_PRO tribe_get_cost()’ is closed to new replies.
