Notice: Function _load_textdomain_just_in_time was called incorrectly. Translation loading for the pue-sales domain was triggered too early. This is usually an indicator for some code in the plugin or theme running too early. Translations should be loaded at the init action or later. Please see Debugging in WordPress for more information. (This message was added in version 6.7.0.) in /home/staging-poc/public_html/wp-includes/functions.php on line 6114

Notice: Function _load_textdomain_just_in_time was called incorrectly. Translation loading for the better-click-to-tweet domain was triggered too early. This is usually an indicator for some code in the plugin or theme running too early. Translations should be loaded at the init action or later. Please see Debugging in WordPress for more information. (This message was added in version 6.7.0.) in /home/staging-poc/public_html/wp-includes/functions.php on line 6114

Notice: Function _load_textdomain_just_in_time was called incorrectly. Translation loading for the pue-amazon domain was triggered too early. This is usually an indicator for some code in the plugin or theme running too early. Translations should be loaded at the init action or later. Please see Debugging in WordPress for more information. (This message was added in version 6.7.0.) in /home/staging-poc/public_html/wp-includes/functions.php on line 6114

Notice: Function _load_textdomain_just_in_time was called incorrectly. Translation loading for the pue-stats domain was triggered too early. This is usually an indicator for some code in the plugin or theme running too early. Translations should be loaded at the init action or later. Please see Debugging in WordPress for more information. (This message was added in version 6.7.0.) in /home/staging-poc/public_html/wp-includes/functions.php on line 6114

Notice: Function _load_textdomain_just_in_time was called incorrectly. Translation loading for the wordpress-seo domain was triggered too early. This is usually an indicator for some code in the plugin or theme running too early. Translations should be loaded at the init action or later. Please see Debugging in WordPress for more information. (This message was added in version 6.7.0.) in /home/staging-poc/public_html/wp-includes/functions.php on line 6114
Another espresso_table question - date formatting | Event Espresso - Staging Server

Support

Home Forums Custom Files Another espresso_table question – date formatting

Another espresso_table question – date formatting

Posted: November 13, 2013 at 11:46 am

Viewing 4 reply threads


Yolande Grill

November 13, 2013 at 11:46 am

Sorry guys, back for more! I am using the espresso_table.php custom file template, how do I go about changing the date format? The table currently displays dates as:

Monday, Jun 16, 2014

Can you make it so that the day of the week is abbreviated and the month is fully written out? So for example: Mon, June 16, 2014 would be our ideal format. I’ve got a lot of other things to work on at the moment and don’t have time to search on php date formatting so I figured I’d ask. I also have another quick question that I will just throw in here as well:

When you add an event to your shopping cart and then view your cart it shows the events name/date/time, the ticket name/price/ticket amount dropdown, and then it’s got text that says ‘You can register a maximum of X attendees for this event.’

What would be the easiest way to get rid of that text? I looked through the templates and didn’t find anything.

Thanks!


Sidney Harrell

  • Support Staff

November 13, 2013 at 12:15 pm

The easiest way to get rid of that text is with some CSS:

.reg-allowed-limit {
display: none;
}

And for espresso_table.php, I think you want line 198:

<?php $date = date( get_option('date_format'), strtotime($event->start_date) ); ?>

Instead of using the WP defined date_format, you would specify with:

<?php $date = date( 'D, F j, Y', strtotime($event->start_date) ); ?>


Yolande Grill

November 14, 2013 at 12:13 am

Thanks Sydney, the css worked and I ended up just needing to change the date format I had in my espresso table file (it appears to be different and shorter line wise than what you posted) to ‘D, F j, Y’ and it’s working how it should!

I’ve got one last quick question. When you add an event to your cart and view your cart, how do you get the number of tickets for that event to default to 1 instead of 0? A coworker and I have looked around the forums for answer and have yet to find one with code that will work for us.

Thanks!


Anonymous

November 14, 2013 at 7:15 am

Hi Yolanda,

The simplest way to do this is via jQuery.

Josh posted an exmaple here http://staging.eventespresso.com/topic/cart-ticket-dropdown-defaults-to-0/


Yolande Grill

November 14, 2013 at 9:54 am

Thank you Tony, that one worked!

Viewing 4 reply threads

The support post ‘Another espresso_table question – date formatting’ 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 - Staging Server