Browsing All Posts filed under »Rails app«

Add rich text editor in a rails app

August 13, 2011

0

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… [Read more…]

Nice JQuery Plugin

August 13, 2011

0

I recently found out a very nice JQuery plugin. http://dipi-graphics.com/labs/6/NavDock-jQuery-Plugin.html 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

0

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… [Read more…]

Some Core Rails Helper for Ruby

August 10, 2011

3

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… [Read more…]

Programming Language

August 9, 2011

0

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… [Read more…]

Select in form_for in Rails 3

July 11, 2011

0

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… [Read more…]

Rake 0.9 breaks. !!

June 27, 2011

0

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… [Read more…]

CONNECT 2 DATABASES IN A SINGLE RAILS APPLICATION

June 22, 2011

0

Many a times , the need of the situation is to connect ,multiple databases to a single rails app. This seems to be a bit complex issue since we are all used to connect a single database to a rails app. But after some googling, I found out that in rails, it’s a damn simple… [Read more…]

DEPLOY A RAILS 3 APP IN RACKSPACE

June 20, 2011

0

EDIT: TO INSTALL MYSQLITE AND SQLITE3 USE THE FOLLWING: yum install mysql-server mysql-libs mysql-devel yum install sqlite sqlite-devel THIS INSTALLS THE LIBRARIES gem install sqlite3-ruby THIS INSTALLS THE GEM The steps to setup/deploy your rails application on a rackspace cloud server are given below. The steps given below worked for me. Along with the steps… [Read more…]

Why is Ruby on Rails preferred over JAVA and PHP?

June 20, 2011

2

 Ruby on Rails is more object-oriented than PHP, thus providing all the inherent advantages of an object-oriented language such as simplicity, modularity, modifiability, extensibility, maintainability and re-usability. Ruby on Rails is a web framework whereas PHP is only a scripting language. Ruby on Rails includes a web server for development, whereas a web server has to be… [Read more…]

Follow

Get every new post delivered to your Inbox.