Events can be grouped by date formats or by categories, tags or custom taxonomies.
Events can be grouped by days, weeks, months and some funkier options that no one will probably ever use, but I liked the challenge! Actually I imagined one could do some seasonal styling perhaps? each grouping has it’s own css classes, and date/time format
Grouping also allows one to do timetables (grouped by day), weekly schedules, or monthly, quarterly or seasonal event views.
Some applications will cope with the html, but there are other applications which do not. EG: Google calendar – does not faciliate html nor issue it in feed.
HTML in the description field is not explicitly forbidden, however it is probably not recommended. There is some provision for html to be explicitly allowed for, either:
in the description using an ALTREP parameter,
or in an ‘experiemental’ X field, X-ALT-DESC,
WordPress allows us to create events with html in them. So what to do when the ics feed is generated?
Retaining the html – two possibilties:
Link to the html representation:
DESCRIPTION;ALTREP="http://www.example.com/somepath/":This is an example description.
Provide separate field with html representation:
Outlook will recognise:
X-ALT-DESC;FMTTYPE=text/html:<p>This is an example description.</p>
This update does both, as well of course ,as stripping the html from the description field in the ics file. This means images will be stripped too (only for the feed – do not panic!)
Your events all have a link to their post or custom post type.
You can switch the hover text off (see widget settings)
Using amr-ical-events-list (or an external ics file)?
In an ics file sometimes (quite often?) there is no event URL. To deal with this, you have the following:
one can specify a default url (such as a calendar page) , so that if people click on the event in the widget, they go to the default event url. (See below for configuration)
either for the list type
or in the widget settings
Configuration of the Default Event URL for the widget events
The purpose of this post is to explain the custom html style file option. There are already many html options. Please explore those first before resorting to your own.
This option is for advanced users only with good html and css knowledge and very specific requirements.
Html styles:
A number of html styles or structures in which to report events have already been defined for you. The box calendar styles have some very logic also attached to them.
The next release of this wordpress events plugin will have the following pluggable functions. Before going this route, please consider whether you can achieve what you want with “list types” or your own custom “list html style” and realise that you will be on your own with debugging your own code!
where key is one of the key values in the event array, $content is the base content or value of that propery, $ event is passed in case the default formatting routine needs access to other event information (eg: to generate a link etc).
This function will call other formatting functions if necessary, eg: amr_format_allday(), or amr_format_date(). See the ical_events_list_main.php file. You could also call these individually. (Or they could become pluggable at special request – go to the forum)
If you have timezones that you need to cope with and are not using amr_format_value(), you will probably want to use
amr_format_date( $format, $date);
where
date is a datetime object.
format is a php format string
This will deal with the timezones for you, and convert the event date into the display timezone of the website or page.
Most of the time, people have chosen to go with one of the default list types provided. I had hoped to see some weird and wonderful stylings when I offered all this flexibility and styling options, and yes there have been some nice ones
However the possibilities are greater. Now that the amr-events plugin is gaining momentum, I am hoping to see some exciting designs! To aid this, there is a new page on how to configure the listtypes.
Try the search box – I spent quite a bit of time looking for a good wordpress search plugin, and decided on Mikko Saari‘s Relevanssi – better than google as one can emphasis the tags, and so it gives better results.
Some of you may be wondering why the promised new event plugin is taking so long……
One reason is that some friends have needed some support (a whirlwind of mindblowing medical drama hitting the family) so plugin development had to take a back seat.
Another reason is firefox.
Being the thorough person that I am, I’m aiming that the new plugin will allow one to create whatever repeating event one wants to create. For example: events that repeat every 5th x day of the month. Some examples of all the wild and wonderful possibilities to allow and test for are here and here (scroll down to the rrule). This means that a fairly sophisticated event entry form is required that can be simple, but can also expand to allow for the more interesting specifications.
HTML FORMS SELECT MULTIPLE in Firefox
At first this meant at least allowing “Select multiple” input and so I coded the select and validated it. Then I added the multiple….
I could not get it to work in firefox.
At first, I drove myself batty thinking I had the wrong syntax, maybe the css was stuffing it up? maybe the php code was wrong etc, maybe the wordpress code was interfering. Every time I made the validated SELECT a “multiple”, the dropdown arrow disappeared, making the input non functional. A quick bit of googling showed that maybe there was a firefox problem there. Other browers were handling it better.
SELECT MULTIPLE or CHECKBOXES?
I decided I could not spend more time on it, and converted the areas that needed to allow multiple selection to checkboxes hidden initially using javascript – still only two clicks, with the plus that if those values are set, we can display them automatically on page load. Possibly this is more user friendly, I said to myself, as some non-tech folks struggle with selecting multiple options in a dropdown, wheres most are used to “opening” a box and then they can see all the checkboxes that they can click on.
HMTL FORMS RADIO buttons and CHECKBOX in Firefox
GroundHog Day! So now I had some complicated radio and checkbox php and html happening. Again it was driving me nuts, random buttons were shown as on, when they should not have been. I kept thinking it was a bug in my code (ok there were some to start, which is why it is godd to keep validating the code). Then I found that firefox was happier if it had some MORE html bracketing the sets of checkboxes, so I gave it more. Actually I think the nested checkboxes inside another checkbox fieldset were what broke it. More fieldsets sorted it out.. Chrome, Safari and IE seemed OK either way.
I love the debugging add-ons in firefox (firebug and web developer) and have not been able to comfortably replicate those in other browers. Normal I would test it out more to find a workaround, but I had already wasted hours and felt I needed to move forward with the developement. If anyone has any info to shed on either of these and how to get around them, please let me know – post a comment below.