Posted: February 18, 2013 at 3:37 pm
|
Event Espresso site environment: WordPress 3.5.1. Event Espresso v3.1.30.7.P Events Calendar v2.0.4 Social Media v1.1.4 Event Registration Page: http://www.paintnplay.net/event-registration/?regevent_action=register&event_id=29 I am just looking to show remaining seats available. I found a similar post on your old forum at https://eventespresso.com/forums/2010/12/show-number-of-remaining-tockets/ , and as suggested I added this code: Available Spaces: [ATTENDEE_NUMBERS event_id=1 type=available_spaces] to the html of the above Registration Page.Then I went to add this code [<?php echo do_shortcode('[ATTENDEE_NUMBERS event_id=1 type=available_spaces]')] to the suggested widget.php, but that PHP file is not with all the themes other php files, or in other common php file locations. Should I create a Widget.php file? Thank you for your time and expertise.
|
Hello Leesa, That forum post is outdated. 🙂 You shouldn’t create a widget.php file. You can modify the registration_page_display.php and move it and registration_page.php both to your uploads/espresso/templates directory. You will need to add the following code somewhere around line 100 or 101 of registration_page_display.php:
|
|
|
Hi Jonathan, Thank you for your speedy response! Were would those two php file reside? |
Hello, Sorry for the delay. Those files will be in wp-content/plugins/event-espresso/templates, but need to be moved to wp-content/uploads/espresso/templates to prevent them from being overwritten during an update. |
|
|
Jonathan, That worked like a charm! Thank you!! Any chance there is a way to enlarge the font for the display of > Available Spaces: 30 |
|
You’ll want to wrap that text in a div or span and give it an id so that you can put a rule into your CSS file to modify it.
and then add the CSS rule to one of the CSS files:
Then play with the value to get the size you want. |
|
Well, I thought the short code was working. It is, but the math is incorrect. It only displays the correct total if you are actually logged into the wordpress website. For example, with the below link… the Available Spaces = 30. Four people paid, so total should now display Available Spaces = 26. It does, but you have to be logged in to the website. Once you log out, the total returns to Available Spaces = 30 Event example: Admin screen shot: (shows 4 paid) I hope you can help. |
|
Hello Leesa, I just tested this out locally and both logged in and out it reduced the available spaces count correctly. Have you tried clearing your browser cache? Or is there a caching plugin on your site and is it caching Event Espresso pages? |
|
Hello Dean, Thank you for your reply! It was a cache setting issue! Problem solved! Have a fantastic day! |
|
Great, glad it’s sorted! |
The support post ‘Show Remaining Seats’ 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.