Home › Forums › Ticket Products › Event Tickets Plus › woocommerce tickets
- This topic has 7 replies, 2 voices, and was last updated 10 years, 11 months ago by
Geoff.
-
AuthorPosts
-
May 26, 2015 at 6:43 am #965059
Jamie
GuestBefore I buy a business licence for this plugin, I need to know if it has the option of showing the number of remaining tickets for an event on the front end?
So if I have an event with 30 seats and 2 are sold, I need the site to dispay that there are only 28 seats remaining on the page. does this plugin include this feature?
Thanks
May 26, 2015 at 10:20 am #965161Geoff
MemberHi Jamie, and thanks for checking out WooCommerce Tickets. I really hope it’s a good fit for your site. 🙂
Great question! The remaining tickets do not display on the front end by default. However, there is a way to make that happen with a few lines of code.
Would this work for you? Please let me know.
Cheers!
GeoffMay 27, 2015 at 1:22 am #965286Jamie
GuestHi Geoff, thanks for the quick reply. Yes I’d be happy to add a few lines of code if you’d be kind enough to let me know what and where to add it. Much appreciated. Jamie
May 27, 2015 at 7:13 am #965319Geoff
MemberHi Jamie, thanks for following up!
Sure thing–this answer in that same thread will give you the step-by-step instructions. 🙂
Did you have any other  pre-sales questions about WooCommerce Tickets that I could help with? Please let me know.
Cheers!
GeoffMay 27, 2015 at 8:36 am #965348Jamie
ParticipantHi Geoff, I followed those instructions adding the code and it gives me an error:
“There is a syntax error on line 65. Code hinting may not work until you fix this error”
Here is the code I added…
$is_there_any_product_to_sell = true;
} else {
echo “<span class=’tickets_nostock’>” . esc_html__( ‘Out of stock!’, ‘tribe-wootickets’ ) . “</span>”;
}
echo “</td>”;echo “<td nowrap=’nowrap’ class=’tickets_name’>”;
echo $ticket->name;
echo “</td>”;echo “<td nowrap=’nowrap’ class=’tickets_stock’>”;
echo $ticket->stock . ‘ left’;
echo “</td>”;echo “<td class=’tickets_price’>”;
echo $this->get_price_html( $product );
echo “</td>”;echo “<td class=’tickets_description’>”;
echo $ticket->description;
echo “</td>”;echo “</tr>”;
}Do you have any advice?
May 27, 2015 at 9:53 am #965373Geoff
MemberHi Jamie,
That’s strange, it seems to work well when I try it on my end.
Perhaps try removing the code that was added, then copying the block of code that is above it, then replacing this line:
[php]echo $ticket->name;[/php]
…with this:
[php]echo $ticket->stock . ‘ left’;[/php]
Cheers!
GeoffP.S. I’m going to move this thread to our WooCommerce Ticket forum since it seems we’ve moved from Pre-Sales to support. 🙂
May 27, 2015 at 12:32 pm #965408Jamie
ParticipantAh perfect, worked a treat. Thanks for your help
May 27, 2015 at 12:36 pm #965410Geoff
MemberMy pleasure! Thanks again for reaching out and I’m glad you picked up WooCommerce Tickets. 🙂
Feel free to start a new thread if any other questions pop up and we’d be happy to help.
Cheers!
Geoff -
AuthorPosts
- The topic ‘woocommerce tickets’ is closed to new replies.
