Calendar Helper plugin
Plugin details
Documentation
Install the plugin:
ruby script/plugin install http://topfunky.net/svn/plugins/calendar_helper
Example usage
This generates the simplest possible calendar:
calendar(:year => 2005, :month => 6)
This generates a calendar, as before, but the 's class is set to "calendar_helper":
calendar({:year => 2005, :month => 6, :table_class => "calendar_helper"})
This generates a simple calendar but shows the entire day name ("Sunday", "Monday", etc.) instead of only the first three letters:
calendar(:year => 2005, :month => 6, :abbrev => (0..-1))
This generates a simple calendar, but gives special days (days that are in the array listOfSpecialDays) one CSS class, "specialDay", and gives the rest of the days another CSS class, "normalDay". You can also use this highlight today differently from the rest of the days, etc:
calendar(:year => 2005, :month => 5) do |d| if listOfSpecialDays.include?(d) [d.mday, {:class => "specialDay"}] else [d.mday, {:class => "normalDay"}] end end
Further Documentation
There is currently no advanced documentation for this plugin.
New documentationEdit plugin | (0 older versions) | Last edited by: maxim_kulkin, 8 months ago

