Browsing All Posts filed under »Rails app«

Add rich text editor in a rails app

August 13, 2011


Hi, I just came across a requirement to add a rich text editor in my web application made in rails. I used TinyMCE for this. I loved the small js based editor not because of the features but because of the customization options it provides. Here I show u a simple way to integrate TinyMCE […]

Nice JQuery Plugin

August 13, 2011


I recently found out a very nice JQuery plugin. I havent tried it yet but will try it soon.. From the demo…its worth a shot !!

Using Gradient in HTML using simple CSS

August 12, 2011


In this post I show(after some googling) how to use gradients(color transitions) in your html using simple CSS. I am putting the CSS code below. This code can be pasted in the css file of your project. you have to create a div with id as “gradient”. Alternatively, you can paste this code in style […]

Some Core Rails Helper for Ruby

August 10, 2011


The Core Extensions are ActiveSupport’s collection of extensions to Ruby’s core classes and modules. They are basic design patterns solving problems that are encountered often in Ruby. These methods are one level below the Rails API; they are the internal functions that Rails uses. Class:Array–> ————————————————————————————————————————————- Conversions core_ext/array/conversions.rb • Array#to_sentence joins the array’s elements and […]

Programming Language

August 9, 2011


The primary purpose of source code should not be expressing implementation to a computer; it should be expressing meaning to people. Programming languages are an incredibly expressive and terse medium for the concepts programmers talk about. Proposals to make programming languages more English-like inevitably fail not because of poor implementation but because there is an […]

Select in form_for in Rails 3

July 11, 2011


I have often been confused about form helpers in rails. Recently I was doing a project in which I had to use select tag. So finally after spending a lot of time on this trivial things I figured it out. Its very simple….lemme explain (or I must say lemme show u how stupid I was […]

Rake 0.9 breaks. !!

June 27, 2011


Recently I was doing a rails project where I did a normal rake db:migrate I got an error like this: rake aborted! uninitialized constant Rake::DSL /usr/lib/ruby/1.9.1/rake.rb:2482:in `const_missing'  /usr/lib/ruby/gems/1.9.1/gems/rake-0.9.0/lib/rake/tasklib.rb:8:in `<class:TaskLib>'  /usr/lib/ruby/gems/1.9.1/gems/rake-0.9.0/lib/rake/tasklib.rb:6:in `<module:Rake>'  /usr/lib/ruby/gems/1.9.1/gems/rake-0.9.0/lib/rake/tasklib.rb:3:in `<top (required)>'  /usr/lib/ruby/gems/1.9.1/gems/rake-0.9.0/lib/rake/rdoctask.rb:20:in `require' /usr/lib/ruby/gems/1.9.1/gems/rake-0.9.0/lib/rake/rdoctask.rb:20:in `<top (required)>'  /usr/lib/ruby/gems/1.9.1/gems/railties-3.0.7/lib/rails/tasks/documentation.rake:1:in `require'  /usr/lib/ruby/gems/1.9.1/gems/railties-3.0.7/lib/rails/tasks/documentation.rake:1:in `<top (required)>' /usr/lib/ruby/gems/1.9.1/gems/railties-3.0.7/lib/rails/tasks.rb:15:in `load' /usr/lib/ruby/gems/1.9.1/gems/railties-3.0.7/lib/rails/tasks.rb:15:in `block in <top (required)>'  /usr/lib/ruby/gems/1.9.1/gems/railties-3.0.7/lib/rails/tasks.rb:6:in `each'  /usr/lib/ruby/gems/1.9.1/gems/railties-3.0.7/lib/rails/tasks.rb:6:in `<top […]