We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

RepEEt questions

Development and Programming

joshclark17's avatar
joshclark17
194 posts
16 years ago
joshclark17's avatar joshclark17

Hi All- I just found Brent Wilson’s RepEEt plugin and am super excited about it. However, I’m having one little (but very BIG) problem in implementing it. The site I have set up doesn’t have a ton of events, but they do require some repeating events. I want to list all of the events, using repeat and have them appear on a template - like:

www.web.com/index.php/events

However, the only way I can seem to get repEEt to work is to add the year to the url, like this:

www.web.com/index.php/events/2009

I’m wondering if anyone knows how to make repEEt work where the events flow without having to add the year to the url structure? Here is the code I’m working with:

{exp:repeet:parse date_header_interval="month"} 
{repeet:date_header}<h3>%F, %Y</h3>{/repeet:date_header}
      {repeet:no_results}Oops, looks like there aren't any events in the time range you specified.{/repeet:no_results}

      {exp:repeet:get_ids weblog="events" parse="inward" show_future_entries="yes"}
  
        {exp:weblog:entries weblog="events" entry_id="{repeet:entry_ids}" dynamic="off" status="open" show_expired="no" 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_date}{/repeet:exclude_dates}
          {repeet:display}
            <div class="event_entry"><h4><a href="http://{url_title_path=" title="{title}">{title}</a></h4>
<strong>{repeet:start_time format="%F %d, %Y"}</strong>
{event_time}</div>
          {/repeet:display}
        {/repeet:item}
        {/exp:weblog:entries}

      {/exp:repeet:get_ids}
 {/exp:repeet:parse}

Thanks for any input!

       
emagine media's avatar
emagine media
65 posts
16 years ago
emagine media's avatar emagine media

I added it to the url structure through the link to the calendar itself, see below for my navigation code. Basically I have a conditional in place that if the calendar link is called from the categories list, it gives me a link with the current year and month as a starting off point. It’s a bit of a workaroud, but does work.

{assign_variable:this_category="Events"}
{assign_variable:default_nav_on="events_calendar"}
{assign_variable:current_month="{current_time format='%m'}"}
{assign_variable:current_year="{current_time format='%Y'}"}

{exp:weblog:categories id="sub_nav" weblog="content_pages" show="3|29|30|31"}
  {if '{category_name}' == 'Events Calendar'}
  {if '{category_name}' != '{this_category}'}
      <a href="http://{site_url}{segment_1}/{category_url_title}/{current_year}/{current_month}class=nav_on">{/if}{category_name}{if '{category_name}' != '{this_category}'}</a>
  {/if}
  {if:else}
  {if '{category_name}' != '{this_category}'}
      <a href="http://{site_url}{segment_1}/{category_url_title}class=nav_on">{/if}{category_name}{if '{category_name}' != '{this_category}'}</a>
  {/if}
  {/if}
{/exp:weblog:categories}
       
mr_tim's avatar
mr_tim
43 posts
16 years ago
mr_tim's avatar mr_tim

I too am having this issue of http://www.mysite.com/index.php/events not displaying full results, with Repeet requiring a year or year/month e.g. http://www.mysite.com/index.php/events/2009/05.

From an SEO and usability point of view you really want to use a base URL rather than a rolling one with the current month appended. Is there any way around this?

       
mr_tim's avatar
mr_tim
43 posts
16 years ago
mr_tim's avatar mr_tim

No ideas on solving this one?

       

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.