Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

WordPress

John Locke
John Locke
15,479 Points

Anyone know of a good plugin in (or coded solution) for this?

I'm working on a client project, they have recurring events and times that they want displayed on the home page in a certain fashion. My ideal solution is to give them an easy back-end interface that allows them to enter events and time for each day of the week, so those can stay put most of the time, but be changed easily.

My first thought was Advanced Custom Posts, this seems troublesome on the home page. Could I call the individual values later if there were a specific custom post type that had this interface?

Perhaps a custom meta box interface on said custom post? The clients in put the times and text values. On the home page, in the specific div, Do a single loop, Query the specific post type, echo out "Monday" , the field for monday_text, the field for monday_times, repeat for each day of the week, End the loop?

A regular calendar view is not what I'm after. Ideally, it's a series of values that I can echo out.

I've looked at various Events List plugins - almost seeing a solution in some of them, but not quite.

Let me know if you have any thoughts on this. Thanks!

3 Answers

Zac Gordon
STAFF
Zac Gordon
Treehouse Guest Teacher

Sweet! Definitely let us know which one worked best for you!

John Locke
John Locke
15,479 Points

I ended up trying all of these plugins tonight, plus a few more. All-In-One was pretty close, but still seemed overly complicated for both my end and the client end. I ended up creating a new custom post type Events, adding a Parent Category called Days, with sub-categories for each day of the week.

In a template part, there are headers with the day of the week, under those headers, it loops through a custom query (one for each day) that looks for published events with the category that fits that particular day. This allows for the same recurring event to be posted to multiple days with a single checkbox. The title is the name of the event, the content is simple the time the event reoccurs at. Ta-da.

Thanks for your help, Zac; I simply had to think about it for a bit.

Zac Gordon
Zac Gordon
Treehouse Guest Teacher

I love it John Locke! That's a quote right there: "I simply had to think about it" ;p

Glad you got something working that fit your needs just right.

Zac Gordon
STAFF
Zac Gordon
Treehouse Guest Teacher

A few options:

  1. All-in-One Event Calendar
  2. Events Calendar Pro
  3. Event Organizer
  4. FT Calendar
  5. Post Recycle
  6. Event Calendar Scheduler
  7. My Calendar

I've used one or two of these before but I can't remember which one :p Hope one of these help meet your needs!

John Locke
John Locke
15,479 Points

Thank you Zac. I will run through these and see which one works best for this project. :D

Matt Campbell
Matt Campbell
9,767 Points

Baring in mind that calendars consist of custom post types and meta fields etc, and are then just fancified with some jquery and css, surely you can just run the calendar plugins loop for where you want posts to be and do a conditional that says if today's date is the same as the value the calendar has saved for date, then run the loop and change the title to today's date?

Just the first thing that comes to mind but I'm knackered so may be a rubbish idea. lol.