Welcome To Snipplr


Everyone's Recent Snippets Tagged rails



0 1935 posted 17 years ago by eugegim
0 1656 posted 17 years ago by eugegim
1 1792 posted 18 years ago by pmaciver
2 2493 posted 18 years ago by pmaciver
1 2175 posted 18 years ago by tonic
I normally paste this into config/mongrel.rb, then add "require 'mongrel'" in my config/deploy.rb Once that's done, you'll be able to start, stop, and restart your mongrels like so: `cap deploy:mongrel:start/stop/restart`
3 2160 posted 18 years ago by jimmyebaker
Been wanting to made one of these for a while and finally I got round to it. For some examples please visit the post: http://www.dom111.co.uk/blog/coding/db/8 Any comments suggestions appreciated. CreativeCommons ShareAlike
3 3718 posted 18 years ago by dom111
Send file from different name
1 1896 posted 18 years ago by tonic
alternative to using DateTime.now.to_s
1 2183 posted 18 years ago by jhenry
2 2725 posted 18 years ago by tonic
1 2185 posted 18 years ago by mikegreen
I didn't create this but I use it all the time. Just drop it in lib/tasks/fixtures.rake
1 1627 posted 18 years ago by markpercival
1 1630 posted 18 years ago by klunkatronic
"When using haml, an HTML tag is represented using %tagname, but in the case of an HTML tag with attributes, the representation is %tagname{:attribute => value}. It turns out there must be no whitespace between %tagname and {:attribute => value}....
1 1853 posted 18 years ago by cczona
"The new naming scheme for template (eg. .html.erb) does not seem to work for partials. When using :partial => 'form' a filename "_form.html.erb" is not recognized. " Rails now requires the partial to be referenced by dotted format
1 1939 posted 18 years ago by cczona
0 1786 posted 18 years ago by javierarce