r3volution11
Forum Replies Created
-
No, query_posts doesn’t work with the posts_per_page parameter. I wish it did as I am having trouble getting @jrgreenfield1’s linked solution to work correctly for me.
query_posts works perfectly but doesn’t limit events. Stinks.
Hey guys, this is awesome, thank you so much.
Problem though: It’s not working correctly for me. It’s only listing one event when there are 8 upcoming. Are there any extra bits of code that you both may have forgotten to mention?
Here is my code:
<div> <?php $calender = get_cat_ID( 'Events' ); $calender_link = get_category_link( $calender );?> <?php global $spEvents; $spEvents->loadDomainStylesScripts();?> <div id="tec-content main" class="upcoming"> <div id="tec-events-loop" class="tec-events post-list clearfix"> <?php $todaysDate = date('Y-m-d G:i:s'); $cal_query = new wp_query('category_name=Events&posts_per_page=5&meta_key=_EventStartDate&meta_compare=>=&meta_value='.$todaysDate.'&orderby=meta_value&order=ASC'); ?> <?php while ($cal_query->have_posts()) : $cal_query->the_post(); ?> <div id="post-<?php the_ID() ?>" class="tec-event <?php echo $alt ?>"> <div style="clear:both;"></div> <ul><?php the_title('<div class="event-title"><a href="' . get_permalink() . '" title="' . the_title_attribute('echo=0') . '" rel="bookmark">', '</a></div>'); ?> <?php echo the_event_start_date( null, false ); ?></ul> <!-- End tec-event-entry --> </div> <!-- End post --> <?php $alt = ( empty( $alt ) ) ? ' alt' : '';?> <?php endwhile; // posts ?> </div> </div> </div>
That doesn’t work right either. It’s like The Events Calendar is constantly debating what the time really is.
So I edited the code to this:
$b = time() – 58200;
$todaysDate = date(‘Y-m-d G:i:s’,$b);
$whereClause = ” AND d1.meta_key = ‘_EventStartDate’ AND d2.meta_key = ‘_EventEndDate’ “;
// Is the start date in the future?
$whereClause .= ‘ AND ( d1.meta_value > “‘.$todaysDate.'” ‘;Still trying to figure out what time The Events Calendar and/or WordPress thinks it is. The 58200 is seconds. Not sure how to just set it in hour increments.
Forum: Plugins
In reply to: [Plugin: The Events Calendar] Todays event not showing in widget…Justin, I’ve purposefully offset the time to -12 UTC just to try to get it to work to no avail.
I’ve definitely went over all of the simple stuff several times.
It’s got to be an error in the code some where.
Forum: Plugins
In reply to: [Plugin: The Events Calendar] Todays event not showing in widget…BTW, I’m guessing that this will only work based on the servers local time.
Forum: Plugins
In reply to: [Plugin: The Events Calendar] Todays event not showing in widget…Found a fix that seems to be working so far:
On line 546 of template-tags.php change .$spEvents->date. to .$todaysDate.
Then make a new line before the first $whereClause
Put the following:
$todaysDate= date(‘Y-m-d G:i:s’);
Some how The Events Calendar’s internal clock is messed up so this tells the query to go by the correct time.
Forum: Plugins
In reply to: [The Events Calendar] [Plugin: The Events Calendar] Reoccuring eventsIn a post written by the developer 3 weeks ago, he stated the plugin would not be supported for a few months.
So I’d say it won’t be any time soon.
Forum: Plugins
In reply to: [Plugin: The Events Calendar] Todays event not showing in widget…No, the event is disappearing the day of the event.
Example:
Today is July 19th. Current time is 11:30AM.
Event is July 19th at 8:00PM.
Event is not appearing on the widget.
Forum: Plugins
In reply to: [MailPress] [Plugin: MailPress] Generated Links In Emails Not WorkingThis issue arises from the Tracking add-on.
Forum: Plugins
In reply to: [WordTour] [Plugin: WordTour] Can't create new Venue, Artist, or TourI can’t get the javascript error to appear unfortunately. I’ll try again and notify you ASAP.
Forum: Plugins
In reply to: [Plugin: The Events Calendar] Todays event not showing in widget…Any solution to this? Definitely a big issue.
Yes it looks like this issue has come back.
Forum: Plugins
In reply to: [Plugin: The Events Calendar] Todays event not showing in widget…CHM82, Where’d you put that? I’m having the same problem (I posted about it yesterday but got no reply).
Another interesting thing I just noticed. I set the time to UTC -12 and out of no where they went missing again. So I set the timezone city to New York and now they’re back. Weird.