|
Ruby on Rails for PHP and Java Developers
The web framework Ruby on Rails for developing database based web applications provides a Model-View-Controller framework. The required web server WEBrick is included with Ruby on Rails. The framework is configured with the MySQL database by default, but may be configured with another database.
The book covers developing web applications
with Ruby on Rails. Technologies discussed include Ajax, directory services, and web services. A comparison is made with PHP, the most commonly used scripting language for developing web applications.
1 Ruby
1.1 Introduction
1.2 Installing Ruby
1.3 Creating a Ruby Application
1.4 Identifiers and Comments
1.5 Strings
1.6 Arrays Hashes and Ranges
1.7 Variables Constants and Operators
1.8 Classes
1.9 Methods
1.10 Procs and Blocks
1.11 Control Structures and Iterators
1.12 Exception Handling
1.13 Modules
1.14 Comparing Ruby with PHP
1.15 Comparing Ruby with Java
1.16 Summary
2 Rails Framework
2.1 Introduction
2.2 Overview of Rails
2.3 Active Record
2.4 Action Controller
2.5 Action View
2.5.1 Sub-Templates
2.6 Ruby on Rails Commands
2.7 Installing Rails
2.8 Developing a Rails Application
2.9 Rails Routes
2.10 Stylesheets
2.11 Helpers
2.12 Layouts
2.13 Partials
2.14 Rails Framework Examples
2.15 Configuring Rails with the MySQL Database
2.16 Comparing Rails with PHP
2.17 Comparing Rails with Java
2.18 Summary
3 CRUD on Rails
3.1 Introduction
3.2 Scaffolding
3.3 CRUD with PHP
3.4 CRUD with Java
3.5 Creating a Rails Application
3.6 Creating a Database Table
3.7 Migrations
3.8 Creating catalogs Table with Migrations
3.9 Configuring with Oracle Database
3.10 Configuring with SQL Server 2005 Database
3.11 Developing a CRUD Application
3.11.1 Creating Dynamic Scaffolding
3.11.2 Creating Scaffolding with Scaffold Generator
3.12 Ajax Scaffolding
3.13 Validations
3.14 Summary
4 Ajax on Rails
4.1 Introduction
4.2 Overview of Ajax
4.3 Overview of XMLHttpRequest
4.4 Creating an XMLHttpRequest Object
4.5 Opening an HTTP Request
4.6 Sending an HTTP Request
4.7 Processing an HTTP Response
4.8 Ajax with PHP
4.9 Ajax with Java
4.10 Support for Ajax in Rails
4.10.1 link_to_remote
4.10.2 form_remote_tag
4.10.3 submit_to_remote
4.10.4 observe_field
4.10.5 observe_form
4.10.6 periodically_call_remote
4.10.7 update_element_function
4.10.8 update_page
4.11 Creating a Ruby on Rails Application
4.12 Creating a Database Table
4.13 Sending a Request
4.13.1 Sending a Request with form_remote_tag Method
4.13.2 Sending a Request with observe_field Method
4.14 Processing a Request
4.15 Processing the Response
4.16 Summary
5 Creating PDF and Excel Reports
5.1 Introduction
5.2 Creating a PDF with PHP
5.3 Creating a PDF with Java
5.4 Creating a PDF File with Ruby on Rails
5.5 Creating a Table in PDF
5.6 Creating a Spreadsheet with PHP
5.7 Creating a Spreadsheet with Java
5.8 Creating an Excel Spreadsheet with Ruby on Rails
5.9 Creating a Spreadsheet with Ruby Spreadsheet
5.10 Summary
6 XML On Rails
6.1 Introduction
6.2 Processing XML with PHP 5
6.3 Processing XML with Java
6.4 Installing XML Builder
6.5 Creating an XML Document with Ruby on Rails
6.6 Creating an XML Document from a Database
6.7 Parsing an XML Document with REXML
6.8 Summary
7 PHP On Rails
7.1 Introduction
7.2 Installing PHP
7.3 Installing PHPOnTrax
7.4 Creating a Trax Application
7.5 Creating a CRUD Application
7.6 Summary
8 LDAP On Rails
8.1 Introduction
8.2 Installing OpenLDAP
8.3 Installing Tivoli Directory Server
8.4 Installing Oracle Internet Directory
8.5 LDAP with PHP
8.6 LDAP with Java
8.7 Installing NET::LDAP
8.8 Creating a Rails Application
8.9 Creating a Directory Entry
8.10 Modifying a Directory Entry
8.11 Searching a Directory
8.12 Deleting a Directory Entry
8.13 Summary
9 Web Services On Rails
9.1 Introduction
9.2 Web Services with PHP
9.3 Web Services with Java
9.4 Creating a Web Service with Ruby on Rails
9.5 Web Service API Class
9.6 Dispatching
9.6.1 Direct Dispatching
9.6.2 Delegated Dispatching
9.6.3 Layered Dispatching
9.7 Protocol Clients
9.8 Summary
10 Ruby on Rails in Eclipse
10.1 Introduction
10.2 PHP in Eclipse
10.3 Installing RDT
10.4 Creating a Rails Project in RDT
10.5 Creating a Database Table with RDT
10.6 Creating a CRUD Application with RDT
10.7 Installing RadRails
10.8 Creating a Rails Application with RadRails
10.9 Creating a CRUD Application with RadRails
10.10 Summary
11 Rails Testing and Fixtures
11.1 Introduction
11.2 Unit Testing in PHP and Java
11.3 Rails Example Test
11.4 Assertion Types
11.5 Rails Testing
11.6 Fixtures
11.7 Unit Testing
11.8 Testing Controllers
11.9 Summary
12 Rails in Production
12.1 Introduction
12.2 Setting the Production Mode
12.3 Rails Best Practices and Performance
12.4 Deployment on Apache2 and FastCGI
12.5 Rails Web Hosting
12.6 Summary
|