Introduction to Ruby on Rails

shoulderscobblerInternet and Web Development

Feb 2, 2013 (5 years and 3 months ago)


Introduction to Ruby on Rails

Course Outlines

New Horizons of Syracuse, NY

Glacier Creek Office Park
6711 Towpath Road, Suite 100
East Syracuse, NY 13057
Phone: 315-449-3290
Visit our website at:
New Horizons of Rochester, NY

Calkins Road Business Park
50 Methodist Hill Drive, Suite 50
Rochester, NY 14623
Phone: 585-427-2150

Introduction to Ruby on Rails
Days of Training: 4

This 4-day course focuses on
foundational Ruby and the theory and
practice of Rails. Students will learn
to create database-driven websites
using Ruby on Rails. They will learn
to install Ruby and Rails, Ruby
language constructs and the entire
Rails development stack: domain
modeling with ActiveRecord, controller
and view implementation, testing,
database migrations, data validation
techniques, AJAX fundamentals, and

Lesson 1: Getting Started with Rails
Installing Rails
• Supported database backends
• Ruby installation
• InstantRails for Windows
Creating a new application
• The ‘rails’ command
• Tour of the Rails application layout
Application configuration and
• Creating the databases
• Configuring database.yml
• Setting the default route
Connecting to a Rails application
• Controller/action/id URL semantics
• Dispatcher and routing roadmap
• Examining the log files
Rails tools
• Managing tasks with rake (Ruby make)
• The application console
The Model/View/Controller (MVC)
framework architecture
• Separation of concerns
• MVC in the application directory layout
Lesson 2: Ruby Language Skills and
Running Ruby
• Command-line Ruby
• The Interactive Ruby (irb) console
Objects, variables, and methods
• Basic object-orientation concepts
• Naming conventions
• Variable assignment
• Local vs. instance variables
• Method-calling semantics
• Method arguments and return values
Classes and modules
• Instantiating classes
• Mixing in modules
• Modules as namespaces
Built-in classes
• String
• Array
• Hash
• Symbol
• Numerics
Blocks and iterators
• Blocks vs. methods vs. lambdas
• Collection iteration
• Single-object iteration
• Built-in exceptions
• Writing your own exception classes
• Exceptions in Rails
Lesson 3: Model Design and Database
Domain modeling for Rails and Ruby
• Describing the "what" of the application
• Creating ActiveRecord models with
Object-relational mapping with
• ActiveRecord models and Ruby classes
• ActiveRecord associations
“Rails-friendly” SQL
• Table-naming conventions
• Primary and foreign keys
Database maintenance with ActiveRecord
• Default migrations
• Customizing migrations
• Migrating backwards

Lesson 4: Controller Actions and
View Templates
Basics of controller/view interaction
• Creating controllers and view with
• Default rendering rules
• Shared controller/template instance
• Separating controller logic from view
HTML templating with Embedded
Ruby (ERb)
• Rules of ERb processing
• Layouts
• Using master and partial templates
Fine-tuning controllers and view
• Controller filters
• Redirecting control
• Default and custom view helper
Writing and processing HTML forms in
• Using form helper methods
• "Magic" field initialization from
instance variables
• Accessing CGI data through the
"params" hash
AJAX calls and RJS (Ruby/JavaScript)
• Basic DOM updating with Ajax
• Using RJS for composite Ajax calls
Lesson 5: Application Testing
Rails unit tests
• The Ruby TestUnit framework
• Writing fixturesAddressing test failures
and errors
Lesson 6: Ruby and Rails Resources
Mailing lists
IRC channels

• Experience in HTML is required
• Server-side programming experience
and familiarity with SQL is beneficial.

At Course Completion
Upon successful completion of this
course, students will be able to: • Install and configure Ruby and Rails
• Understand the Model-View-
Controller framework architecture
• Program in Ruby.
• Build database-driven applications
with Ruby on Rails.
• Work with templates.
• Use AJAX in Ruby on Rails
• Test Ruby on Rails Applications.
Page 1 of 1 RUBYINTRO