Support

Home Forums Event Espresso Premium Multiple ticket price display

Multiple ticket price display

Posted: October 28, 2013 at 4:07 pm

Viewing 2 reply threads


Angela Haddon

October 28, 2013 at 4:07 pm

Hi, I’m hoping you can help me with this. I want to display all ticket options and prices in a sidebar (not just in a drop-down box on the registration page); is there a way to pull this data from the Event? I found the following code, which displays the first price in the array only:
<?php echo do_shortcode(‘[EVENT_PRICE event_id=”‘.$event_id.'” number=”0″]’);?>
Thanks again for your continued support!


Dean

October 29, 2013 at 3:22 am

Hi Angela,

Well you could use that code multiple times, changing the number each time

<?php 
echo do_shortcode('[EVENT_PRICE event_id="'.$event_id.'" number="0"]'); //first price
echo do_shortcode('[EVENT_PRICE event_id="'.$event_id.'" number="1"]'); //second price
echo do_shortcode('[EVENT_PRICE event_id="'.$event_id.'" number="2"]'); //third price
?>

You could also take a look at this function https://gist.github.com/Apina/674700c14fe7d751be75 though getting the event id in the sidebar might be tough unless you specify the the event id rather than it being dynamic.


Angela Haddon

October 30, 2013 at 5:14 pm

Hi Dean – that github code worked perfectly and did exactly what I needed it to do; it pulled out all Member Pricing and displayed it in a list. Perfect! Thanks for your help 🙂

Viewing 2 reply threads

The support post ‘Multiple ticket price display’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso