Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums Back End Yet another calendar plugin

  • This topic is empty.
Viewing 1 post (of 1 total)
  • Author
    Posts
  • #32523
    magnuseide
    Member

    Hi
    I posted this over at WPtavern, but it thought I’d get some feedback on it here also.

    I’m currently developing a weekly, horizontal events calendar. It’s made specifically for a WP-theme for a film festival I’ve been working for for the past two years (not as a developer, though I’m making a new site since I refuse to work with the current obsolete system).

    It’s based on a graphic schedule we’ve had included in our festival catalogue (printed), so the format is quite “un-web”, hence the horizontal design.

    You can see an early draft of the web-version here:
    http://flagget.no/animationfestival/en/timeplan

    I’ve added events as a custom post type, where the date and time is stored in a custom meta field as a unix timestamp, and the calendar function uses get_posts() to fetch events within the specified time interval. Currently the main function accepts week number, year, hour range, and day range (if you want to exclude specific days of a week as I’ve done in the example). A number of other meta fields are used for info such as venue, duration, age limit, short description and a few others.

    One of my biggest hurdles so far is the html/css bit of it. Currently each hour is a div with nested divs for each event and a right margin for offsets when an event doesn’t start on the hour. This way, if two events occur within the same hour the first will push the next down one spot. But longer events will overlap other events when they don’t start on the same hour. I was hoping I’d find a html/css solution to this so I’d avoid calculating collisions in php, but alas I’m beginning to think that is unavoidable.

    I’d like any feedback i can get. Positive as negative. If it’s been done before, I’d be happy to hear that, but I haven’t been able to find anything just like what I wanted, and I will continue making it for this particular site.

    Currently it’s only included in the core theme files, but I might make it into a plugin if I’m satisfied with it, and if there is some interest in it.

    If i port it to a plugin I’ll probably add controls to navigate weeks and days, custom options ofc., custom styling, widget support and shortcodes for displaying it, iCalendar, feed etc.

    PS. I’m holding back publishing any code for now since it’s still horribly messy, ungracefully entangled with other funtions in my funtions.php file, and probably only readable by me at the point.

Viewing 1 post (of 1 total)
  • The forum ‘Back End’ is closed to new topics and replies.