Posted by Daniel Butler
Wed, 20 Sep 2006 13:07:00 GMT
Jonathan Viney of New Zealand has announced his date_finder plugin for Ruby on Rails. The plugin allows the following types of actions:
- To find the next five Mondays and Fridays:
DateFinderBase.weekly.day(:monday).day(:friday).find(:max => 5)
- To find the 10th of the month for the next five months:
DateFinderBase.monthly.day_number(10).find(:max => 5)
- To find the last Thursday in September for the next 3 years
DateFinderBase.yearly.month (:september).day(:thursday).day_occurrence(:last).find(:max => 3)
- To find the next 5 Wednesdays on a fortnightly basis (skips every second week):
DateFinderBase.weekly(2).day(:wednesday).find(:max => 5)
To install, execute script/plugin install http://svn.viney.net.nz/things/rails/plugins/date_finder.
Thanks, Jonathan.
Date Finder @ Ruby Plugins Directory
Posted in Ruby on Rails | Tags plugin | no comments
Posted by Daniel Butler
Thu, 01 Jun 2006 20:48:00 GMT
Belgian Damien Merenne has announced a plugin for Ruby on Rails that allows you to programatically keep track of a user's browsing history in your controllers.
Once enabled, you can use the following methods in your actions:
last_location: returns the last visited location, can be used with one numeric argument precising how many locations to go back in the history (1 by default),
redirect_back: redirect the user to the last location in history, it takes the same arguments as last_location,
store_location: force storing of the current location in the history.
And it's simple enough to use. Just add a bit of code like this to your controllers:
class ApplicationController < ActionController::Base
history :default => "http://default.url.com/",
:max => 10
end
Read about the Rails History Plugin
Posted in Ruby on Rails | Tags plugin | no comments
Posted by Daniel Butler
Thu, 18 May 2006 23:27:00 GMT
Thomas Bayes, 1702-1761
Surendra Singhi of Calcutta, India, has released an extremely useful text classification plugin for Ruby on Rails. Using a Bayesian classifier you can flag comments, email, articles—whatever chunks of text you'd like to keep a handle on so that when you encounter more like it, you can do something automatically with it. Pick some categories, such as 'spam' or 'not spam', 'good' or 'evil', or even 'ironic' and 'irony-free', classify some existing text or data, and then use the method to predict the classification of an unknown text.
Read more for a summary of its usage.
Read more...
Posted in Ruby on Rails | Tags bayes, plugin | 1 comment
View on Alexander Springs Creek, Florida (May 2005)