The Forgotten Ruby Web Frameworks

Posted by RussianGeek Wed, 07 Nov 2007 07:06:00 GMT

Everyone knows Rails but have you heard of Nitro, Ramaze, Sinatra, IOWA or Cerise?
Nice overview these frameworks from InfoQ: read.

Posted in  | Tags  | no comments | no trackbacks

Creating an RSS feed in Ruby on Rails

Posted by RussianGeek Tue, 06 Nov 2007 09:36:00 GMT

If you want to create an RSS feed in Ruby on Rails you MUST read this article: Paulsturgess Snippets.

Posted in ,  | Tags  | no comments | no trackbacks

Shared hosting and Rails version upgrades

Posted by RussianGeek Thu, 23 Aug 2007 06:29:00 GMT

The hoster've upgraded a version of Rails and your site is down?
To prevent such a surprising news freeze the stable version of Rails to your application: "rake rails:freeze:gems".
That command copies GemRails into the vendor/rails directory.

Posted in ,  | Tags , ,  | no comments | 61 trackbacks

Allow empty value for validates_uniqueness_of

Posted by RussianGeek Thu, 09 Aug 2007 11:02:00 GMT

This nice validator has :allow_nil for check if the value is null but what about empty value?
To allow empty values also, just add to the validator: before_validation { |u| u.property_name = nil if u.property_name.blank? }

Posted in ,  | Tags ,  | no comments | no trackbacks

Rails Models relationships

Posted by RussianGeek Wed, 01 Aug 2007 06:33:00 GMT

Have to tell Rails how your tables are related? has_many, belongs_to or maybe has_and_belongs_to_many?
Take a look at the article.

Posted in ,  | Tags ,  | no comments | 93 trackbacks

Validation numeric value

Posted by RussianGeek Mon, 30 Jul 2007 07:02:00 GMT

Validation of numeric value in RoR uses validates_numericality_of but if the value is optional there is still exception checking it. If you want to skip the check for NULL (nil in Ruby) value just add ":allow_nil => true" to validator.

Posted in ,  | Tags ,  | 2 comments | 52 trackbacks

Forms in Ruby on Rails

Posted by RussianGeek Mon, 09 Jul 2007 06:15:00 GMT

Forms methods in Rails are vague, at the first glance at least... This article may be very helpful to a beginner.

The article dive into deep waters of RoR forms:
- form_for
- remote_form_for
- form_tag
- form_remote_tag

Update: Next installment about forms in Ruby: Part 2.

Posted in ,  | Tags , ,  | 2 comments | 19 trackbacks

Restart Rails on a shared host

Posted by RussianGeek Sun, 08 Jul 2007 20:04:00 GMT

There are many articles, helpers, sites about installing RoR site, gems, plugins etc. and at the end of it you may see: "restart the application".
It took me time to find out how to do it on a shared hosting and I must immortalize it here for my descendants: "pkill -9 -u `whoami` -f dispatch.fcgi".

Update: Sometimes the restart is not enough - you almost certainly need to manually delete your session objects. I use a command like this: rake purge_sessions_table (db-based sessions).

Posted in ,  | Tags ,  | 1 comment | no trackbacks

Small, light-weight forum in Rails

Posted by RussianGeek Sun, 08 Jul 2007 06:32:00 GMT

During my searches of forum on RoR, I found a small, light-weight forum in Rails called Beast.
It looks nice and simple. I'll definitely try it on one of my sites...

Posted in  | Tags ,  | 1 comment | no trackbacks

Oracle is hiring Ruby on Rails developers

Posted by RussianGeek Sat, 07 Jul 2007 12:12:00 GMT

Don't you know?
"If you love to build Web 2.0 style applications (preferably using Ruby on Rails), we’re interested in you." (Oracle Labs)

Posted in  | Tags , ,  | 472 comments | 196 trackbacks

Older posts: 1 2 3 4


eXTReMe Tracker