Hello,
I’ve got Repeet working for a calendar. But I also need to display a list of events for the current week.
Reading through the manual and tring the various examples non do quite what I need - and most seem to rely on the date being in the URL, which my current site set up doesn’t.
This is the code I’ve been playing with:
{exp:repeet:parse date_header_interval="week"}
{repeet:date_header}%M %d, %Y{/repeet:date_header}
{repeet:no_results}Oops, looks like there aren't any events in the time range you specified.{/repeet:date_header}
{exp:repeet:get_ids weblog="events" parse="inward"}
{exp:weblog:entries weblog="events" entry_id="{repeet:entry_ids}" dynamic="off" show_expired="yes" show_future_entries="yes"}
{repeet:item}
{repeet:entry_date}{entry_date format="%Y-%m-%d %H:%i"}{/repeet:entry_date}
{repeet:expiration_date}{expiration_date format="%Y-%m-%d %H:%i"}{/repeet:expiration_date}
{repeet:interval}{repeat_interval}{/repeet:interval}
{repeet:include_dates}{include_dates}{/repeet:include_dates}
{repeet:exclude_dates}{exclude_dates}{/repeet:exclude_dates}
{repeet:display}
<h2><a href="http://{url_title_path=" title="{title}">{title}</a></h2>
{summary}
<a href="http://{url_title_path=" title="Get more information about {title}">Details</a>...
{/repeet:display}
{/repeet:item}
{/exp:weblog:entries}
{/exp:repeet:get_ids}
{/exp:repeet:parse}Which just pulls entries from the Monday of the current week - but nothing from the rest of the week. There’ are entries for every day.
Any help would be greatly appreciated.
Thanks,
Matthew
<ul class="events" >
{exp:repeet:parse date_header_interval="day" }
{repeet:date_header}<li class="date">%l</li>{/repeet:date_header}
{repeet:no_results}Oops, looks like there aren't any events in the time range you specified.{/repeet:date_header}
{exp:repeet:get_ids weblog="events" parse="inward" begin="today" end="1 week" }
{exp:weblog:entries weblog="events" entry_id="{repeet:entry_ids}" dynamic="off" show_expired="yes" show_future_entries="yes" }
{repeet:item}
{repeet:entry_date}{entry_date format="%Y-%m-%d %H:%i"}{/repeet:entry_date}
{repeet:expiration_date}{expiration_date format="%Y-%m-%d %H:%i"}{/repeet:expiration_date}
{repeet:interval}{eventRepeat}{/repeet:interval}
{repeet:include_dates}{include_dates}{/repeet:include_dates}
{repeet:exclude_dates}{exclude_dates}{/repeet:exclude_dates}
{repeet:display}
<li>
<a href="http://{title_permalink=calendar/events}">_ <span class="title">{title}</span>_ </a>
</li>
{/repeet:display}
{/repeet:item}
{/exp:weblog:entries}
{/exp:repeet:get_ids}
{/exp:repeet:parse}
</ul>Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.