Ruby on Rails Tutorial

by Michael Hartl

Published 7 December 2010

Ruby on Rails™ Tutorial by Michael Hartl has become a must-read for developers learning how to build Rails apps.”

Peter Cooper, Editor of Ruby Inside

 

Using Rails, developers can build web applications of exceptional elegance and power. Although its remarkable capabilities have made Ruby on Rails one of the world’s most popular web development frameworks, it can be challenging to learn and use. Ruby on Rails™ Tutorial, Second Edition, is the solution. Best-selling author and leading Rails developer Michael Hartl teaches Rails by guiding you through the development of your own complete sample application using the latest techniques in Rails web development. The updates to this edition include all-new site design using Twitter’s Bootstrap; coverage of the new asset pipeline, including Sprockets and Sass; behavior-driven development (BDD) with Capybara and RSpec; better automated testing with Guard and Spork; roll your own authentication with has_secure_password; and an introduction to Gherkin and Cucumber.

 

You’ll find integrated tutorials not only for Rails, but also for the essential Ruby, HTML, CSS, JavaScript, and SQL skills you’ll need when developing web applications. Hartl explains how each new technique solves a real-world problem, and he demonstrates this with bite-sized code that’s simple enough to understand, yet novel enough to be useful. Whatever your previous web development experience, this book will guide you to true Rails mastery.

 

This book will help you

  • Install and set up your Rails development environment
  • Go beyond generated code to truly understand how to build Rails applications from scratch
  • Learn test-driven development (TDD) with RSpec
  • Effectively use the Model-View-Controller (MVC) pattern
  • Structure applications using the REST architecture
  • Build static pages and transform them into dynamic ones
  • Master the Ruby programming skills all Rails developers need
  • Define high-quality site layouts and data models
  • Implement registration and authentication systems, including validation and secure passwords
  • Update, display, and delete users
  • Add social features and microblogging, including an introduction to Ajax
  • Record version changes with Git and share code at GitHub
  • Simplify application deployment with Heroku

Ruby on Rails 2.3 Tutorial

by Michael Hartl

Published 1 November 2010
The Ruby on Rails 2.3 Tutorial teaches web development with Ruby on Rails, an open-source web framework that powers many of the web's top sites, including Twitter, Hulu, and the Yellow Pages. Ruby on Rails 2.3 Tutorial helps you learn Rails by example through the development of a substantial sample application, including a site layout, a user data model, a full registration and authentication system, user-status associations, social "following," and a feed of status updates. Ruby on Rails 2.3 Tutorial also teaches good software development practices, including version control with Git and GitHub, test-driven development with RSpec, and instant deployment with Heroku. Though of necessity the book focuses on a specific sample application, the emphasis throughout this book is on general principles, so you will have a solid foundation no matter what kind of web application you want to build.  

RailsSpace

by Michael Hartl and Aurelius Prochazka

Published 20 July 2007
Ruby on Rails is fast displacing PHP, ASP, and J2EE as the development framework of choice for discriminating programmers, thanks to its elegant design and emphasis on practical results. RailsSpace teaches you to build large-scale projects with Rails by developing a real-world application: a social networking website like MySpace, Facebook, or Friendster.

Inside, the authors walk you step by step from the creation of the site's virtually static front page, through user registration and authentication, and into a highly dynamic site, complete with user profiles, image upload, email, blogs, full-text and geographical search, and a friendship request system. In the process, you learn how Rails helps you control code complexity with the model-view-controller (MVC) architecture, abstraction layers, automated testing, and code refactoring, allowing you to scale up to a large project even with a small number of developers.

This essential introduction to Rails provides



A tutorial approach that allows you to experience Rails as it is actually used
A solid foundation for creating any login-based website in Rails
Coverage of newer and more advanced Rails features, such as form generators, REST, and Ajax (including RJS)
A thorough and integrated introduction to automated testing

The book's companion website provides the application source code, a blog with follow-up articles, narrated screencasts, and a working version of the RailSpace social network.