For 2023 (and 2024 ...) - we are now fully retired from IT training. We have made many, many friends over 25 years of teaching about Python, Tcl, Perl, PHP, Lua, Java, C and C++ - and MySQL, Linux and Solaris/SunOS too. Our training notes are now very much out of date, but due to upward compatability most of our examples remain operational and even relevant ad you are welcome to make us if them "as seen" and at your own risk.
Lisa and I (Graham) now live in what was our training centre in Melksham - happy to meet with former delegates here - but do check ahead before coming round. We are far from inactive - rather, enjoying the times that we are retired but still healthy enough in mind and body to be active!
I am also active in many other area and still look after a lot of web sites - you can find an index ((here)) |

Well House Consultants
You are on the site of
Well House Consultants
who provide
Open Source Training Courses
and business
hotel accommodation. You are welcome to browse and use
our resources subject to our copyright statement and to add in links from your pages to ours.
Other subject areas - resources
Java Resources
Well House Manor Resources
Perl Resources
Python Resources
PHP Resources
Object Orientation and General topics
MySQL Resources
Linux / LAMP / Tomcat Resources
Well House Consultants Resources
Extras Resources
C and C++ Resources
Ruby Resources
Tcl/Tk Resources
Web and Intranet Resources
|
Ruby module R202
Ruby on Rails
Exercises, examples and other material relating to training module R202. This topic is presented on public course Ruby on Rails
Background Ruby is a great, pragmatic langauge and Rails lets you
use it by providing the framework through which you can interface
databases to you ruser's browser, using the framework of Rails
and the glue of Ruby. Ruby can be embedded within pages at a
View level, built in, or used at the Controller level via
ApplicationController classes. This module opens the door
on a very powerful and effective system. Related technical and longer articles Ror - Ruby on Rails
Articles and tips on this subject | updated | 4013 | Web Frameworks - nested templates There are times when an inversion of long-accepted logic makes sense. I've been working in a many-floored office block in Salford this week, with a bank of lifts to travel between floors. Rather than press a button for your floor once you're in the lift, you press a button in the lift lobby when you ... | 2013-02-23 | 4010 | Really Simple Rails Rails is a "Web Framwork" that uses code written in the Ruby language to do the things that vary from one web application to another. There are a huge number of features common to many web applications, and by using a framework you can save yourself the trouble of rewriting all these common things, ... | 2013-02-17 | 3919 | What is a web framework? When you write web applications, there are many features you'll need which mirror features other people have needed too. Now - there's nothing to stop you writing your own code (maybe in Ruby, Python or Perl) including these features ... but wouldn't it be better to use the feature set that someone ... | 2012-11-17 | 3777 | Multiple views in a single appication - sharing common parts of the template - Ruby on Rails So far ... we have installed Rails, and written a simple application with a single model, controller and view. In this article, I'll show you how to add a second controller method, and view, while sharing much of the view template. The example takes the scenario of a database of products where you ... | 2012-06-23 | 2605 | Ruby on Rails - a sample application to teach you how The Ruby on Rails Framework is a great way to put bolt web applications together quickly - but it can be overwhelming when you come to do it for the first time. There's a steep learning curve with all the various elements to put together to make up the whole.
We have a first (tiny!) demonstration in ... | 2012-06-23 (longest) | 3780 | Ruby of Rails - cleanly displaying model data in the view The display of data from our model has - thus far - been formatted in the Controller (when that really ought be in the view) and has been liable to fail to display properly if the data contains HTML special characters such as < and &. The solution to this is provided for you by rails - simply ... | 2012-06-23 | 3779 | Adding validation to form entries and sticky fields - Ruby on Rails So far, we have implemented an MVC application under Ruby in Rails, and provided a rudimentary form to allow the user to add rows to the model. In this section, we show you the extra code needed to validate the data, and to echo it back out to the user within the form if it's incorrect.
1. In the model, ... | 2012-06-23 | 3778 | Providing a form to allow the user to add data to the model - Ruby on Rails So far, we have implemented a single model - view - controller application using Ruby on Rails, and displayed the data in several forms. How do we add new data? We need to provide an "add product" form, and code to handle that form when it's submitted. Building on the example so far, here's how:
Adding ... | 2012-06-23 | 3772 | Hello World - Ruby on Rails - a checklist of each step Ruby on Rails is a framework under which web applications written in Ruby can be run on a web server, via a browser. You could make your own applications from first principles, but Rails does most of this for you already, so it's typically going to be a huge resource saving for you as you write and maintain ... | 2012-06-23 (longer) | 3756 | Ruby on Rails - how it flows, and where the files go Ruby on Rails is a web framework that lets you use Ruby code to add dynmaics to your web site, using the MVC (Model, View, Controller) architecture that keeps the look and feel of the page (View) apart from the business logic (Model), linking the two via the Controller. Rails provides the framework ... | 2012-06-09 | 3624 | Why do we need a Model, View, Controller architecture? In the very early days of the web, it was a source of data - with files of marked up text (in HTML) being sent out to a browser program by a server running on a central computer. Requests to the central server were made in http (Hypertext transfer protocol), and the responses were translated by the ... | 2012-03-03 | 1745 | Moodle, Drupal, Django (and Rails) In the 1970s, we had C and in that decade and the following one, we put together our systems in that language and its derivatives.
In the 1990s, we had Perl and in that decade and the following one, we put together our systems in that language are related ones.
In the 2010s, we'll have a wide range ... | 2010-01-31 | 1302 | Ruby, Ruby, Ruby. Rails, Rails, Rails. We passed through New York on our way up from Washington DC to Albany, NY State; a 3-hour layover gave us a chance for a quick meal (there's no better city for a choice of foods), and a chance to look through a book store (there's no better country to look through the shelves for the next trend).
Our ... | 2010-01-31 | 1050 | The HTML++ Metalanguage What's the difference between a language and a metalanguage?
A language is a single specification - a way of describing a series of actions or how some particular data is handled. Whereas a metalanguage is a way of specifying a series of languages to a particular pattern.
An example? HTML is a language. ... | 2010-01-31 | 2607 | Answers on Ruby on Rails What is Ruby on Rails?
Ruby on Rails is a clever way of programming your web server in Ruby - it allows you to have data in databases on your website and provide very easy access tothat data through a browser, allowing your customers to see the data and you staff to see it, alter it, and add more data ... | 2010-01-31 (longer) | 2609 | Scope of variables - important to Ruby on Rails Yesterday's Ruby on Rails training day brought home just how important it is to ensure that your Ruby variables are correctly "scoped" - that you tell Ruby if they're to be local to the method in which they are defined, to be available to all methods that run on the same objects, to all objects of a ... | 2010-01-31 | 1375 | Python v Ruby Ruby v Python ... I've been asked for a comparison!
• Both are object oriented scripting languages - or rather claim to be scripting languages, but are really compile-and-run via their own virtual machines, in just the same way as Perl and Java are.
• Both are modern, Open Source languages ... | 2009-08-31 |
Examples from our training material
Background information
Some modules are available for download as a sample of our material or under an Open Training Notes License for free download from [here].
Topics covered in this module
What is Ruby on Rails? MVC (Model, view, controller) design principles. Rails structures - WEBrick servers, URLs and embedded code. Directory structure. Database connections. Creating the application, the database and tables. First application through Scaffolds. Validation and customising the display. Adding a new controller. Adding viewers and layouts.
Complete learning
If you are looking for a complete course and not just a information on a single subject, visit our Listing and schedule page.
Well House Consultants specialise in training courses in
Ruby,
Lua,
Python,
Perl,
PHP, and
MySQL. We run
Private Courses throughout the UK (and beyond for longer courses), and
Public Courses at our training centre in Melksham, Wiltshire, England.
It's surprisingly cost effective to come on our public courses -
even if you live in a different
country or continent to us.
We have a technical library of over 700 books on the subjects on which we teach.
These books are available for reference at our training centre.
|
|
|