<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-25952467</id><updated>2011-04-21T17:25:16.371-07:00</updated><title type='text'>Khmer Ruby on Rails</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://khmerruby.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/25952467/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://khmerruby.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Socheat Yi</name><uri>http://www.blogger.com/profile/00716074929906192408</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://userpics-27.hi5.com/userpics/927/668/66878927.img.jpg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>4</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-25952467.post-114780999737609095</id><published>2006-05-16T13:04:00.000-07:00</published><updated>2006-05-16T13:06:38.040-07:00</updated><title type='text'>Easy lessons for Ruby on Rails newbies</title><content type='html'>As a newbie, getting started with Rails was tricky without some help from the &lt;a href="http://wiki.rubyonrails.com/rails/pages/IRC" class="existingWikiWord"&gt;&lt;span class="caps"&gt;IRC&lt;/span&gt;&lt;/a&gt; folks.  If you get stuck, that’s a good place for help, as the author hangs out in there pretty regularly.     &lt;p&gt;That said, some sample code is worth its weight in gold, so here’s how I got a basic Rails application running.&lt;/p&gt;      &lt;p&gt;First, check &lt;a href="http://wiki.rubyonrails.com/rails/pages/GettingStartedWithRails" class="existingWikiWord"&gt;GettingStartedWithRails&lt;/a&gt; for some gotchas, and then read &lt;a href="http://api.rubyonrails.org/"&gt;http://api.rubyonrails.org/&lt;/a&gt; for some installation tips.  I will repeat some of it here, but that is where I started.&lt;/p&gt;      &lt;h2&gt;Requirements&lt;/h2&gt;      &lt;p&gt;You can skip a lot of installation problems on Windows by simply using &lt;a href="http://wiki.rubyonrails.com/rails/pages/InstantRails" class="existingWikiWord"&gt;InstantRails&lt;/a&gt;&lt;/p&gt;      &lt;ul&gt; &lt;li&gt;Apache 1.3.x or 2.x (or any &lt;span class="newWikiWord"&gt;FastCGI&lt;a href="http://wiki.rubyonrails.com/rails/pages/FastCGI"&gt;?&lt;/a&gt;&lt;/span&gt;-capable webserver with a mod_rewrite-like module)&lt;/li&gt;&lt;li&gt;&lt;span class="newWikiWord"&gt;FastCGI&lt;a href="http://wiki.rubyonrails.com/rails/pages/FastCGI"&gt;?&lt;/a&gt;&lt;/span&gt; (or mod_ruby) for production performance (CGI is used for development)&lt;/li&gt;&lt;li&gt;Database and &lt;a href="http://wiki.rubyonrails.com/rails/pages/DatabaseDrivers"&gt;driver&lt;/a&gt; (e.g. &lt;a href="http://wiki.rubyonrails.com/rails/pages/MySQL" class="existingWikiWord"&gt;MySQL&lt;/a&gt;, &lt;a href="http://wiki.rubyonrails.com/rails/pages/PostgreSQL" class="existingWikiWord"&gt;PostgreSQL&lt;/a&gt;, or &lt;a href="http://wiki.rubyonrails.com/rails/pages/SQLite" class="existingWikiWord"&gt;SQLite&lt;/a&gt;)&lt;/li&gt; &lt;/ul&gt;      &lt;h2&gt;Optional&lt;/h2&gt;      &lt;p&gt;You can use a &lt;span class="caps"&gt;IDE&lt;/span&gt; to program with Rails.&lt;/p&gt;      &lt;p&gt;Get RadRails at &lt;a href="http://www.radrails.org/"&gt;http://www.radrails.org&lt;/a&gt;&lt;/p&gt;      &lt;h2&gt;Getting started&lt;/h2&gt;      &lt;p&gt;1a. Set up Apache for the Rails application (see “Apache configuration example” below&lt;sup&gt;&lt;a href="http://wiki.rubyonrails.com/rails/pages/Tutorial#fn1"&gt;1&lt;/a&gt;&lt;/sup&gt;.)&lt;br /&gt;or&lt;br /&gt;1b. Run the &lt;a href="http://wiki.rubyonrails.com/rails/pages/WEBrick" class="existingWikiWord"&gt;WEBrick&lt;/a&gt; servlet: &lt;code&gt;ruby script/server  -- help&lt;/code&gt; (see “WEBrick configuration example” below&lt;sup&gt;&lt;a href="http://wiki.rubyonrails.com/rails/pages/Tutorial#fn2"&gt;2&lt;/a&gt;&lt;/sup&gt;.)(Run this from the Rails application directory)&lt;br /&gt;2. Go to &lt;a href="http://rails/"&gt;http://rails/&lt;/a&gt; (or whatever your ServerName is) and check that you get the “Congratulations, you’re on Rails!” screen&lt;br /&gt;2b. In case of &lt;a href="http://wiki.rubyonrails.com/rails/pages/WEBrick" class="existingWikiWord"&gt;WEBrick&lt;/a&gt;, go to &lt;a href="http://localhost:3000/"&gt;http://localhost:3000&lt;/a&gt;. Apache2 note: The httpd.conf contains an entry which determines the port to be used. For example, &lt;strong&gt;ServerName AServerNameHere:80&lt;/strong&gt;, port 80 was selected. Try the following url &lt;a href="http://localhost/"&gt;http://localhost:80/&lt;/a&gt;.&lt;br /&gt;3. Follow the guidelines on the “Congratulations, you’ve put Ruby on Rails!” screen&lt;/p&gt;      &lt;h3&gt;Apache configuration example for Apache 2&lt;/h3&gt;      &lt;p id="fn1"&gt;&lt;sup&gt;1&lt;/sup&gt; In the Apache configuration below, replace ”/path/application” in each case with the full path to the rails directory unpacked with the tar.gz….&lt;/p&gt;      &lt;p&gt;( I am not quite sure what the author means by ” full path to the rails directory unpacked with the tar.gz” In fact it is rather confusing for a ruby newby… I think he means the path that you create by executing “rails /path/to/FILENAME”).&lt;/p&gt;      &lt;p&gt;and be sure to append the “public” or “log” directory where noted below. I also had to turn on &lt;span class="caps"&gt;CGI&lt;/span&gt; and set some access requirements – also shown below (Suse 9.1’s Apache is locked down fairly tight)&lt;/p&gt;    &lt;pre&gt;&lt;virtualhost&gt;&lt;br /&gt;   ServerName rails&lt;br /&gt;   DocumentRoot /path/application/public/&lt;br /&gt;   ErrorLog /path/application/log/apache.log&lt;br /&gt;&lt;br /&gt;   &lt;directory&gt;&lt;br /&gt;     Options ExecCGI FollowSymLinks&lt;br /&gt;     AddHandler cgi-script .cgi&lt;br /&gt;     AllowOverride all&lt;br /&gt;     Order allow,deny&lt;br /&gt;     Allow from all&lt;br /&gt;   &lt;/directory&gt;&lt;br /&gt; &lt;/virtualhost&gt;&lt;br /&gt;&lt;/pre&gt;     &lt;p&gt;An alternative Apache 2 configuration example, that modifies your existing Apache to have a rails enabled directory (rather than a dedicated virtual host) might be&lt;/p&gt;    &lt;pre&gt;Alias /rails/ /var/www/rails/&lt;br /&gt;&lt;directory&gt;&lt;br /&gt; Options ExecCGI&lt;br /&gt; AddHandler cgi-script .cgi&lt;br /&gt; AllowOverride all&lt;br /&gt; Order allow,deny&lt;br /&gt; Allow from all&lt;br /&gt;&lt;/directory&gt;&lt;br /&gt;&lt;/pre&gt;     &lt;p&gt;This alternative configuration will also require&lt;br /&gt;&lt;/p&gt; &lt;pre&gt;RewriteBase /rails&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;to be added to the application’s .htaccess file (in /path/to/application/public), where &lt;em&gt;/rails&lt;/em&gt; is the value supplied to the app’s Alias directive in &lt;em&gt;httpd.conf&lt;/em&gt;.   You should now be able to access your application at:   &lt;ul&gt; &lt;li&gt;&lt;a href="http://example.com/rails/application/public/"&gt;http://example.com/rails/application/public/&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://127.0.0.1/rails/application/public/"&gt;http://127.0.0.1/rails/application/public/&lt;/a&gt;&lt;/li&gt; &lt;/ul&gt;      &lt;h3&gt;WEBrick configuration example&lt;/h3&gt;      &lt;p id="fn2"&gt;&lt;sup&gt;2&lt;/sup&gt; WEBrick servlet help output&lt;/p&gt;    &lt;pre&gt;$ ruby script/server --help&lt;br /&gt;Usage: ruby server [options]&lt;br /&gt;&lt;br /&gt;   -p, --port=port                  Runs Rails on the specified port.&lt;br /&gt;                                    Default: 3000&lt;br /&gt;   -b, --binding=ip                 Binds Rails to the specified ip.&lt;br /&gt;                                    Default: 127.0.0.1&lt;br /&gt;   -i, --index=controller           Specifies an index controller&lt;br /&gt;                                    that requests for root will go to&lt;br /&gt;                                    (instead of congratulations screen).&lt;br /&gt;   -d, --daemon                     Make Rails run as a Daemon (only works if&lt;br /&gt;                                    fork is available -- meaning on *nix).&lt;br /&gt;   -c, --cache-classes              Caches class compilation which will speed up&lt;br /&gt;                                    the serving of requests, but require a&lt;br /&gt;                                    server restart on source changes.&lt;br /&gt;&lt;br /&gt;   -h, --help                       Show this help message.&lt;br /&gt;&lt;/pre&gt;     &lt;h2&gt;Congratulations, you’re on Rails!&lt;/h2&gt;      &lt;p&gt;&lt;em&gt;You’ve successfully configured your web-server to point at this Rails application.&lt;/em&gt;&lt;/p&gt;      &lt;p&gt;Once you have seen this in your web browser, your rails application is ready to begin programming.  Follow these steps:&lt;/p&gt;      &lt;p&gt;1. &lt;a href="http://wiki.rubyonrails.com/rails/pages/TutorialStepOne" class="existingWikiWord"&gt;TutorialStepOne&lt;/a&gt; – Create empty production and test databases for your application.&lt;br /&gt;2. &lt;a href="http://wiki.rubyonrails.com/rails/pages/TutorialStepTwo" class="existingWikiWord"&gt;TutorialStepTwo&lt;/a&gt; – Edit &lt;code&gt;config/database.yml&lt;/code&gt; with your database settings.&lt;br /&gt;3. &lt;a href="http://wiki.rubyonrails.com/rails/pages/TutorialStepThree" class="existingWikiWord"&gt;TutorialStepThree&lt;/a&gt; – Create a new controller using the &lt;code&gt;script/generate controller&lt;/code&gt; generator&lt;br /&gt;(run with no arguments for documentation).&lt;br /&gt;4. &lt;a href="http://wiki.rubyonrails.com/rails/pages/TutorialStepFour" class="existingWikiWord"&gt;TutorialStepFour&lt;/a&gt; – Create a new model using the &lt;code&gt;script/generate model&lt;/code&gt; generator&lt;br /&gt;(run with no arguments for documentation).&lt;br /&gt;5. &lt;a href="http://wiki.rubyonrails.com/rails/pages/TutorialStepFive" class="existingWikiWord"&gt;TutorialStepFive&lt;/a&gt; – See all the tests run and the app documentation be created by running &lt;code&gt;rake&lt;/code&gt;.&lt;br /&gt;6. &lt;a href="http://wiki.rubyonrails.com/rails/pages/TutorialStepSix" class="existingWikiWord"&gt;TutorialStepSix&lt;/a&gt; – Develop your Rails application!&lt;br /&gt;7. Setup &lt;span class="newWikiWord"&gt;FastCGI&lt;a href="http://wiki.rubyonrails.com/rails/pages/FastCGI"&gt;?&lt;/a&gt;&lt;/span&gt; or mod_ruby to get production-level performance&lt;/p&gt;      &lt;h2&gt;Resources&lt;/h2&gt;      &lt;ul&gt; &lt;li&gt;&lt;a href="http://documentation.rubyonrails.com/"&gt;Ruby On Rail Documentation&lt;/a&gt; – documentation page linking to documentation and further tutorials.&lt;/li&gt;&lt;li&gt;&lt;a href="http://wiki.rubyonrails.com/rails/pages/onlampTutorialRevised" class="existingWikiWord"&gt;onlampTutorialRevised&lt;/a&gt; – Some code improvements on the ONLamp-Rails-Tutorials&lt;/li&gt; &lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/25952467-114780999737609095?l=khmerruby.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://khmerruby.blogspot.com/feeds/114780999737609095/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=25952467&amp;postID=114780999737609095' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/25952467/posts/default/114780999737609095'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/25952467/posts/default/114780999737609095'/><link rel='alternate' type='text/html' href='http://khmerruby.blogspot.com/2006/05/easy-lessons-for-ruby-on-rails-newbies.html' title='Easy lessons for Ruby on Rails newbies'/><author><name>Socheat Yi</name><uri>http://www.blogger.com/profile/00716074929906192408</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://userpics-27.hi5.com/userpics/927/668/66878927.img.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-25952467.post-114484835114263464</id><published>2006-04-12T06:24:00.000-07:00</published><updated>2006-04-12T06:26:09.740-07:00</updated><title type='text'>Ruby on Rails Framework</title><content type='html'>, often called &lt;b&gt;RoR&lt;/b&gt; or just &lt;b&gt;Rails&lt;/b&gt;, is an &lt;a href="http://en.wikipedia.org/wiki/Open_source" title="Open source"&gt;open source&lt;/a&gt; &lt;a href="http://en.wikipedia.org/wiki/Web_application_framework" title="Web application framework"&gt;web application framework&lt;/a&gt; written in &lt;a href="http://en.wikipedia.org/wiki/Ruby_programming_language" title="Ruby programming language"&gt;Ruby&lt;/a&gt; that closely follows the &lt;a href="http://en.wikipedia.org/wiki/Model-View-Controller" title="Model-View-Controller"&gt;Model-View-Controller&lt;/a&gt; (MVC) architecture. &lt;p&gt;It strives for simplicity and allowing real-world applications to be developed in less code than other frameworks and with a minimum of configuration.&lt;/p&gt; &lt;p&gt;The Ruby programming language allows for extensive &lt;a href="http://en.wikipedia.org/wiki/Metaprogramming" title="Metaprogramming"&gt;metaprogramming&lt;/a&gt;, which Rails makes much use of. This results in a very readable syntax, in the opinion of many of its users.&lt;/p&gt; &lt;p&gt;Rails is primarily distributed through &lt;a href="http://en.wikipedia.org/wiki/RubyGems" title="RubyGems"&gt;RubyGems&lt;/a&gt;, which is the official packaging format and distribution channel for Ruby libraries and applications.&lt;/p&gt;&lt;br /&gt;&lt;p&gt; &lt;/p&gt;&lt;h2&gt;History&lt;/h2&gt; &lt;p&gt;Ruby on Rails was extracted from &lt;a href="http://www.basecamphq.com/" class="external text" title="http://www.basecamphq.com"&gt;Basecamp&lt;/a&gt;, a project-management tool, by &lt;a href="http://en.wikipedia.org/wiki/37signals" title="37signals"&gt;37signals&lt;/a&gt;. It was first released to the public in July 2004.&lt;/p&gt; &lt;ul&gt;&lt;li&gt;Version 1.0 was released &lt;a href="http://en.wikipedia.org/wiki/December_13" title="December 13"&gt;December 13&lt;/a&gt;, &lt;a href="http://en.wikipedia.org/wiki/2005" title="2005"&gt;2005&lt;/a&gt;.&lt;/li&gt;&lt;li&gt;Version 1.1 was released &lt;a href="http://en.wikipedia.org/wiki/March_28" title="March 28"&gt;March 28&lt;/a&gt;, &lt;a href="http://en.wikipedia.org/wiki/2006" title="2006"&gt;2006&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt; &lt;div class="editsection" style="float: right; margin-left: 5px;"&gt;[&lt;a href="http://en.wikipedia.org/w/index.php?title=Ruby_on_Rails&amp;action=edit&amp;amp;section=3" title="Edit section: Rails' MVC architecture"&gt;edit&lt;/a&gt;]&lt;/div&gt; &lt;p&gt;&lt;a name="Rails.27_MVC_architecture" id="Rails.27_MVC_architecture"&gt;&lt;/a&gt;&lt;/p&gt; &lt;h2&gt;Rails' MVC architecture&lt;/h2&gt; &lt;p&gt;The pieces of the &lt;a href="http://en.wikipedia.org/wiki/Model-View-Controller" title="Model-View-Controller"&gt;Model-View-Controller&lt;/a&gt; (MVC) architecture in Ruby on Rails are as follows:&lt;/p&gt; &lt;div class="editsection" style="float: right; margin-left: 5px;"&gt;[&lt;a href="http://en.wikipedia.org/w/index.php?title=Ruby_on_Rails&amp;action=edit&amp;amp;section=4" title="Edit section: Model"&gt;edit&lt;/a&gt;]&lt;/div&gt; &lt;p&gt;&lt;a name="Model" id="Model"&gt;&lt;/a&gt;&lt;/p&gt; &lt;h3&gt;Model&lt;/h3&gt; &lt;p&gt;In object-oriented, database-driven MVC web applications, &lt;i&gt;Model&lt;/i&gt; consists of the classes representing &lt;a href="http://en.wikipedia.org/wiki/RDBMS" title="RDBMS"&gt;RDBMS&lt;/a&gt; tables.&lt;/p&gt; &lt;p&gt;In Ruby on Rails, Model classes are handled through the &lt;a href="http://en.wikipedia.org/wiki/Active_Record" title="Active Record"&gt;Active Record&lt;/a&gt;. Usually, all the programmer needs to do is to subclass the &lt;code&gt;ActiveRecord::Base&lt;/code&gt; class, and the program will automatically figure out which &lt;a href="http://en.wikipedia.org/wiki/RDBMS" title="RDBMS"&gt;RDBMS&lt;/a&gt; table to use and what columns the table has.&lt;/p&gt; &lt;p&gt;The class definitions also specify the relations between classes with &lt;a href="http://en.wikipedia.org/wiki/Object-relational_mapping" title="Object-relational mapping"&gt;object-relational mapping&lt;/a&gt; commands. For example, if the class name &lt;code&gt;Image&lt;/code&gt; has a definition &lt;code&gt;has_many :comments&lt;/code&gt;, and there is an instance of &lt;code&gt;Image&lt;/code&gt; named &lt;code&gt;a&lt;/code&gt;, then &lt;code&gt;a.comments&lt;/code&gt; will return an array with all &lt;code&gt;Comment&lt;/code&gt; objects with &lt;code&gt;image_id&lt;/code&gt; equal to &lt;code&gt;a.id&lt;/code&gt;.&lt;/p&gt; &lt;p&gt;The data validation handlers (e.g. &lt;code&gt;validates_uniqueness_of :checksum&lt;/code&gt;) and any update-related handlers (e.g. &lt;code&gt;after_destroy :remove_file&lt;/code&gt;, &lt;code&gt;before_update :update_related_details&lt;/code&gt;) are also specified and implemented in the model class.&lt;/p&gt; &lt;div class="editsection" style="float: right; margin-left: 5px;"&gt;[&lt;a href="http://en.wikipedia.org/w/index.php?title=Ruby_on_Rails&amp;action=edit&amp;amp;section=5" title="Edit section: View"&gt;edit&lt;/a&gt;]&lt;/div&gt; &lt;p&gt;&lt;a name="View" id="View"&gt;&lt;/a&gt;&lt;/p&gt; &lt;h3&gt;View&lt;/h3&gt; &lt;p&gt;In MVC, &lt;i&gt;View&lt;/i&gt; is the display logic, or how the data from the &lt;i&gt;Controller&lt;/i&gt; classes is displayed. In web applications, this frequently consists of a minimal amount of code, interspersed in HTML.&lt;/p&gt; &lt;p&gt;There are currently many ways the views can be handled – the underlying view code is part of the Action Pack. The method in Rails itself is to use &lt;a href="http://en.wikipedia.org/wiki/Embedded_Ruby" title="Embedded Ruby"&gt;Embedded Ruby&lt;/a&gt; (.rhtml files), which are basically fragments of HTML with some Ruby code interspersed, with syntax quite similar to &lt;a href="http://en.wikipedia.org/wiki/JavaServer_Pages" title="JavaServer Pages"&gt;JSP&lt;/a&gt;. HTML and XML can also be constructed programmatically with &lt;a href="http://builder.rubyforge.org/" class="external text" title="http://builder.rubyforge.org/"&gt;Builder&lt;/a&gt; or through &lt;a href="http://home.leetsoft.com/liquid/" class="external text" title="http://home.leetsoft.com/liquid/"&gt;Liquid&lt;/a&gt; template system.&lt;/p&gt; &lt;p&gt;For each method in the controller that needs to display user output, a small HTML code fragment needs to be written. The page layout is described separately from the controller action that displays layouts, and the fragments can also call other fragments.&lt;/p&gt; &lt;div class="editsection" style="float: right; margin-left: 5px;"&gt;[&lt;a href="http://en.wikipedia.org/w/index.php?title=Ruby_on_Rails&amp;action=edit&amp;amp;section=6" title="Edit section: Controller"&gt;edit&lt;/a&gt;]&lt;/div&gt; &lt;p&gt;&lt;a name="Controller" id="Controller"&gt;&lt;/a&gt;&lt;/p&gt; &lt;h3&gt;Controller&lt;/h3&gt; &lt;p&gt;In MVC, &lt;i&gt;Controller&lt;/i&gt; classes respond to user interaction and call the application logic, which in turn manipulates the data in &lt;i&gt;Model&lt;/i&gt; and displays the data through &lt;i&gt;View&lt;/i&gt;. In web-based MVC applications, the &lt;i&gt;Controller&lt;/i&gt; methods are initiated by the user through the web browser.&lt;/p&gt; &lt;p&gt;&lt;i&gt;Controller&lt;/i&gt; implementation is handled through Rails' &lt;a href="http://en.wikipedia.org/wiki/Action_Pack" title="Action Pack"&gt;Action Pack&lt;/a&gt;, which contains the class &lt;code&gt;ApplicationController&lt;/code&gt;. Rails applications simply subclass &lt;code&gt;ApplicationController&lt;/code&gt; and write required actions as methods, which can then be accessed through the web, typically in form of &lt;code&gt;/example/method&lt;/code&gt;, which calls &lt;code&gt;ExampleController#method&lt;/code&gt;, and presents the data using the view file &lt;code&gt;/app/views/example/method.rhtml&lt;/code&gt;, unless the method redirects elsewhere.&lt;/p&gt; &lt;p&gt;Rails also provides out-of-the-box &lt;i&gt;&lt;a href="http://en.wikipedia.org/w/index.php?title=Scaffold_%28programming%29&amp;action=edit" class="new" title="Scaffold (programming)"&gt;scaffolding&lt;/a&gt;&lt;/i&gt;, which can quickly construct most of the logic and views needed to do common operations, such as &lt;a href="http://en.wikipedia.org/wiki/CRUD_%28acronym%29" title="CRUD (acronym)"&gt;CRUD&lt;/a&gt;.&lt;/p&gt; &lt;div class="editsection" style="float: right; margin-left: 5px;"&gt;[&lt;a href="http://en.wikipedia.org/w/index.php?title=Ruby_on_Rails&amp;action=edit&amp;amp;section=7" title="Edit section: Other modules"&gt;edit&lt;/a&gt;]&lt;/div&gt; &lt;p&gt;&lt;a name="Other_modules" id="Other_modules"&gt;&lt;/a&gt;&lt;/p&gt; &lt;h2&gt;Other modules&lt;/h2&gt; &lt;p&gt;In addition to this, Rails also offers some other modules, like &lt;a href="http://en.wikipedia.org/wiki/Action_Mailer" title="Action Mailer"&gt;Action Mailer&lt;/a&gt; for sending &lt;a href="http://en.wikipedia.org/wiki/Email" title="Email"&gt;email&lt;/a&gt; and &lt;a href="http://en.wikipedia.org/wiki/Action_Web_Service" title="Action Web Service"&gt;Action Web Service&lt;/a&gt; for &lt;a href="http://en.wikipedia.org/wiki/SOAP" title="SOAP"&gt;SOAP&lt;/a&gt; and &lt;a href="http://en.wikipedia.org/wiki/XML-RPC" title="XML-RPC"&gt;XML-RPC&lt;/a&gt; support.&lt;/p&gt; &lt;div class="editsection" style="float: right; margin-left: 5px;"&gt;[&lt;a href="http://en.wikipedia.org/w/index.php?title=Ruby_on_Rails&amp;action=edit&amp;amp;section=8" title="Edit section: Ajax on Rails"&gt;edit&lt;/a&gt;]&lt;/div&gt; &lt;p&gt;&lt;a name="Ajax_on_Rails" id="Ajax_on_Rails"&gt;&lt;/a&gt;&lt;/p&gt; &lt;h3&gt;Ajax on Rails&lt;/h3&gt; &lt;p&gt;A separate technology called &lt;a href="http://en.wikipedia.org/wiki/Ajax_%28programming%29" title="Ajax (programming)"&gt;Ajax&lt;/a&gt;, which allows for using &lt;a href="http://en.wikipedia.org/wiki/JavaScript" title="JavaScript"&gt;JavaScript&lt;/a&gt; and &lt;a href="http://en.wikipedia.org/wiki/XML" title="XML"&gt;XML&lt;/a&gt; to process queries by a &lt;a href="http://en.wikipedia.org/wiki/Web_browser" title="Web browser"&gt;web browser&lt;/a&gt; to a &lt;a href="http://en.wikipedia.org/wiki/Webserver" title="Webserver"&gt;webserver&lt;/a&gt; as &lt;a href="http://en.wikipedia.org/wiki/Background_%28computer_software%29" title="Background (computer software)"&gt;background processing&lt;/a&gt; without loading additional &lt;a href="http://en.wikipedia.org/wiki/Webpage" title="Webpage"&gt;webpages&lt;/a&gt;, has been combined with this technology to produce a system referred to as "Ajax on Rails." Rails provides several helpers that make implementing Ajax applications easier.&lt;/p&gt; &lt;p&gt;Rails is host to both the Prototype JavaScript framework, a toolkit providing for Ajax calls and other functionality for often occurring client-side programming tasks, and &lt;a href="http://en.wikipedia.org/wiki/Script.aculo.us" title="Script.aculo.us"&gt;script.aculo.us&lt;/a&gt;, a JavaScript library for user interface enhancement (advanced form controls, visual effects, drag and drop).&lt;/p&gt; &lt;div class="editsection" style="float: right; margin-left: 5px;"&gt;[&lt;a href="http://en.wikipedia.org/w/index.php?title=Ruby_on_Rails&amp;action=edit&amp;amp;section=9" title="Edit section: Web server support"&gt;edit&lt;/a&gt;]&lt;/div&gt; &lt;p&gt;&lt;a name="Web_server_support" id="Web_server_support"&gt;&lt;/a&gt;&lt;/p&gt; &lt;h2&gt;Web server support&lt;/h2&gt; &lt;p&gt;For development and testing, the lightweight &lt;a href="http://en.wikipedia.org/wiki/WEBrick" title="WEBrick"&gt;WEBrick&lt;/a&gt; web server included with Ruby is often used as the application server. For production use, &lt;a href="http://en.wikipedia.org/wiki/Apache_HTTP_server" title="Apache HTTP server"&gt;Apache&lt;/a&gt; or &lt;a href="http://en.wikipedia.org/wiki/Lighttpd" title="Lighttpd"&gt;Lighttpd&lt;/a&gt; with &lt;a href="http://en.wikipedia.org/wiki/FastCGI" title="FastCGI"&gt;FastCGI&lt;/a&gt; is recommended, but any web server with &lt;a href="http://en.wikipedia.org/wiki/Common_Gateway_Interface" title="Common Gateway Interface"&gt;CGI&lt;/a&gt; or &lt;a href="http://en.wikipedia.org/wiki/FastCGI" title="FastCGI"&gt;FastCGI&lt;/a&gt; support will work. On Apache, &lt;a href="http://en.wikipedia.org/wiki/Mod_ruby" title="Mod ruby"&gt;mod_ruby&lt;/a&gt; can help with performance considerably, though its use is frequently discouraged because it is unsafe to share multiple RoR applications on Apache. &lt;a href="http://wiki.rubyonrails.com/rails/pages/mod_ruby" class="external autonumber" title="http://wiki.rubyonrails.com/rails/pages/mod_ruby"&gt;[1]&lt;/a&gt;&lt;/p&gt; &lt;div class="editsection" style="float: right; margin-left: 5px;"&gt;[&lt;a href="http://en.wikipedia.org/w/index.php?title=Ruby_on_Rails&amp;action=edit&amp;amp;section=10" title="Edit section: Database support"&gt;edit&lt;/a&gt;]&lt;/div&gt; &lt;p&gt;&lt;a name="Database_support" id="Database_support"&gt;&lt;/a&gt;&lt;/p&gt; &lt;h2&gt;Database support&lt;/h2&gt; &lt;p&gt;Since the Rails architecture strongly favors database use, an &lt;a href="http://en.wikipedia.org/wiki/RDBMS" title="RDBMS"&gt;RDBMS&lt;/a&gt; system is recommended for data storage, but Rails also supports the &lt;a href="http://en.wikipedia.org/wiki/SQLite" title="SQLite"&gt;SQLite&lt;/a&gt; library if running an RDBMS server is not possible. The database access is entirely abstracted from programmer's point of view, and Rails handles access to all databases automatically – though, if needed, using direct SQL queries is possible. Rails attempts to maintain database-neutrality, application portability over different database systems, and usability of pre-existing databases for Rails application development as much as possible, though due to different feature sets of the RDBMSes, it is not completely guaranteed by the framework alone. Several different RDBMS systems are supported, including &lt;a href="http://en.wikipedia.org/wiki/MySQL" title="MySQL"&gt;MySQL&lt;/a&gt;, &lt;a href="http://en.wikipedia.org/wiki/PostgreSQL" title="PostgreSQL"&gt;PostgreSQL&lt;/a&gt;, &lt;a href="http://en.wikipedia.org/wiki/SQLite" title="SQLite"&gt;SQLite&lt;/a&gt;, IBM &lt;a href="http://en.wikipedia.org/wiki/DB2" title="DB2"&gt;DB2&lt;/a&gt;, &lt;a href="http://en.wikipedia.org/wiki/Oracle_database" title="Oracle database"&gt;Oracle&lt;/a&gt; and &lt;a href="http://en.wikipedia.org/wiki/Microsoft_SQL_Server" title="Microsoft SQL Server"&gt;Microsoft SQL Server&lt;/a&gt;.&lt;/p&gt; &lt;div class="editsection" style="float: right; margin-left: 5px;"&gt;[&lt;a href="http://en.wikipedia.org/w/index.php?title=Ruby_on_Rails&amp;action=edit&amp;amp;section=11" title="Edit section: Projects Using Ruby on Rails"&gt;edit&lt;/a&gt;]&lt;/div&gt; &lt;p&gt;&lt;a name="Projects_Using_Ruby_on_Rails" id="Projects_Using_Ruby_on_Rails"&gt;&lt;/a&gt;&lt;/p&gt; &lt;h2&gt;Projects Using Ruby on Rails&lt;/h2&gt; &lt;p&gt;Major software projects written using Ruby on Rails include:&lt;/p&gt; &lt;ul&gt;&lt;li&gt;&lt;a href="http://en.wikipedia.org/wiki/Instiki" title="Instiki"&gt;Instiki&lt;/a&gt; wiki software&lt;/li&gt;&lt;li&gt;&lt;a href="http://en.wikipedia.org/wiki/Typo_%28content_management_system%29" title="Typo (content management system)"&gt;Typo&lt;/a&gt; weblog software&lt;/li&gt;&lt;/ul&gt; &lt;p&gt;Some major websites and services that are implemented on top of Ruby on Rails include:&lt;/p&gt; &lt;ul&gt;&lt;li&gt;&lt;a href="http://en.wikipedia.org/wiki/Basecamp_%28project_manager%29" title="Basecamp (project manager)"&gt;Basecamp&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://en.wikipedia.org/w/index.php?title=Campfire_%28web-based_group_chat_for_business%29&amp;action=edit" class="new" title="Campfire (web-based group chat for business)"&gt;Campfire&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://en.wikipedia.org/wiki/Backpack_%28personal_information_manager%29" title="Backpack (personal information manager)"&gt;Backpack&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://en.wikipedia.org/wiki/Ta-Da_List" title="Ta-Da List"&gt;Ta-Da List&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://en.wikipedia.org/w/index.php?title=BubbleShare&amp;amp;action=edit" class="new" title="BubbleShare"&gt;BubbleShare&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://en.wikipedia.org/wiki/43_Things" title="43 Things"&gt;43 Things&lt;/a&gt;, 43 Places and 43 People&lt;/li&gt;&lt;li&gt;&lt;a href="http://en.wikipedia.org/w/index.php?title=Spongecell_%28interactive_calendar%29&amp;action=edit" class="new" title="Spongecell (interactive calendar)"&gt;Spongecell&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://en.wikipedia.org/wiki/YubNub" title="YubNub"&gt;YubNub&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://en.wikipedia.org/w/index.php?title=Thingbox.com&amp;amp;action=edit" class="new" title="Thingbox.com"&gt;Thingbox.com&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://en.wikipedia.org/w/index.php?title=Odeo&amp;action=edit" class="new" title="Odeo"&gt;Odeo&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://en.wikipedia.org/wiki/Penny_Arcade_%28comic%29" title="Penny Arcade (comic)"&gt;Penny Arcade&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt; &lt;div class="editsection" style="float: right; margin-left: 5px;"&gt;[&lt;a href="http://en.wikipedia.org/w/index.php?title=Ruby_on_Rails&amp;action=edit&amp;amp;section=12" title="Edit section: Requirements"&gt;edit&lt;/a&gt;]&lt;/div&gt; &lt;p&gt;&lt;a name="Requirements" id="Requirements"&gt;&lt;/a&gt;&lt;/p&gt; &lt;h2&gt;Requirements&lt;/h2&gt; &lt;ul&gt;&lt;li&gt;&lt;a href="http://en.wikipedia.org/wiki/Web_server" title="Web server"&gt;Web server&lt;/a&gt; such as &lt;a href="http://en.wikipedia.org/wiki/Apache_HTTP_Server" title="Apache HTTP Server"&gt;Apache&lt;/a&gt; 1.3.x or 2.x, &lt;a href="http://en.wikipedia.org/wiki/Lighttpd" title="Lighttpd"&gt;lighttpd&lt;/a&gt;, or any &lt;a href="http://en.wikipedia.org/wiki/FastCGI" title="FastCGI"&gt;FastCGI&lt;/a&gt;-capable webserver with a mod_rewrite-like module. For development, Rails' "server" script uses &lt;a href="http://en.wikipedia.org/wiki/WEBrick" title="WEBrick"&gt;WEBrick&lt;/a&gt;, which may be used in place of other web servers. However, WEBrick generally exhibits slow performance and is not recommended for production use.&lt;/li&gt;&lt;li&gt;&lt;a href="http://en.wikipedia.org/wiki/FastCGI" title="FastCGI"&gt;FastCGI&lt;/a&gt; for production performance. &lt;a href="http://en.wikipedia.org/wiki/Common_Gateway_Interface" title="Common Gateway Interface"&gt;CGI&lt;/a&gt; is possible but quite slow. Rails supports Apache's &lt;a href="http://en.wikipedia.org/wiki/Mod_ruby" title="Mod ruby"&gt;mod_ruby&lt;/a&gt;.&lt;/li&gt;&lt;li&gt;Database and driver (e.g. &lt;a href="http://en.wikipedia.org/wiki/MySQL" title="MySQL"&gt;MySQL&lt;/a&gt;, &lt;a href="http://en.wikipedia.org/wiki/PostgreSQL" title="PostgreSQL"&gt;PostgreSQL&lt;/a&gt;, or &lt;a href="http://en.wikipedia.org/wiki/SQLite" title="SQLite"&gt;SQLite&lt;/a&gt;)&lt;/li&gt;&lt;/ul&gt; &lt;div class="editsection" style="float: right; margin-left: 5px;"&gt;[&lt;a href="http://en.wikipedia.org/w/index.php?title=Ruby_on_Rails&amp;action=edit&amp;amp;section=13" title="Edit section: See also"&gt;edit&lt;/a&gt;]&lt;/div&gt; &lt;p&gt;&lt;a name="See_also" id="See_also"&gt;&lt;/a&gt;&lt;/p&gt; &lt;h2&gt;See also&lt;/h2&gt; &lt;ul&gt;&lt;li&gt;&lt;a href="http://en.wikipedia.org/wiki/Mod_ruby" title="Mod ruby"&gt;Mod_ruby&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://en.wikipedia.org/wiki/37signals" title="37signals"&gt;37signals&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt; &lt;div class="editsection" style="float: right; margin-left: 5px;"&gt;[&lt;a href="http://en.wikipedia.org/w/index.php?title=Ruby_on_Rails&amp;action=edit&amp;amp;section=14" title="Edit section: External links"&gt;edit&lt;/a&gt;]&lt;/div&gt; &lt;p&gt;&lt;a name="External_links" id="External_links"&gt;&lt;/a&gt;&lt;/p&gt; &lt;h2&gt;External links&lt;/h2&gt; &lt;ul&gt;&lt;li&gt;&lt;a href="http://www.rubyonrails.org/" class="external text" title="http://www.rubyonrails.org"&gt;Ruby On Rails Project Homepage&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://wiki.rubyonrails.com/" class="external text" title="http://wiki.rubyonrails.com"&gt;Rails Wiki&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://instantrails.rubyforge.org/wiki/wiki.pl?Instant_Rails" class="external text" title="http://instantrails.rubyforge.org/wiki/wiki.pl?Instant_Rails"&gt;Instant Rails&lt;/a&gt; – a Windows installer for Ruby, Rails, Apache, and MySQL&lt;/li&gt;&lt;li&gt;&lt;a href="http://www.rubyonrailsforum.com/" class="external text" title="http://www.rubyonrailsforum.com/"&gt;Ruby on Rails Forum&lt;/a&gt; News and discussion forum.&lt;/li&gt;&lt;li&gt;&lt;a href="http://podcast.rubyonrails.com/" class="external text" title="http://podcast.rubyonrails.com"&gt;Ruby on Rails Podcast&lt;/a&gt; Interviews with Rails developers&lt;/li&gt;&lt;li&gt;&lt;a href="http://rubyonrailsblog.com/" class="external text" title="http://rubyonrailsblog.com"&gt;Ruby on Rails Blog&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/25952467-114484835114263464?l=khmerruby.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://khmerruby.blogspot.com/feeds/114484835114263464/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=25952467&amp;postID=114484835114263464' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/25952467/posts/default/114484835114263464'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/25952467/posts/default/114484835114263464'/><link rel='alternate' type='text/html' href='http://khmerruby.blogspot.com/2006/04/ruby-on-rails-framework.html' title='Ruby on Rails Framework'/><author><name>Socheat Yi</name><uri>http://www.blogger.com/profile/00716074929906192408</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://userpics-27.hi5.com/userpics/927/668/66878927.img.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-25952467.post-114484809104007349</id><published>2006-04-12T06:21:00.000-07:00</published><updated>2006-04-12T06:21:37.286-07:00</updated><title type='text'>Download Ruby</title><content type='html'>&lt;div class="section"&gt; &lt;h3&gt;How to get Ruby.&lt;/h3&gt; &lt;ul&gt;&lt;li&gt;The stable release &lt;a href="ftp://ftp.ruby-lang.org/pub/ruby/ruby-1.8.4.tar.gz"&gt;ruby-1.8.4&lt;/a&gt;.&lt;/li&gt;&lt;li&gt;The CVS branch for the development version is available. See &lt;a href="http://www.ruby-lang.org/en/20020106.html"&gt;CVS Repository Guide&lt;/a&gt; &lt;/li&gt;&lt;/ul&gt; &lt;h3&gt;Downloadable Items&lt;/h3&gt; &lt;ul&gt;&lt;li&gt;&lt;a href="ftp://ftp.ruby-lang.org/pub/ruby/ruby-1.8.4.tar.gz"&gt;Ruby version 1.8.4 source (stable release)&lt;/a&gt; and its &lt;a href="http://rubyforge.org/frs/?group_id=426"&gt;rubyforge mirror &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="ftp://ftp.ruby-lang.org/pub/ruby/stable-snapshot.tar.gz"&gt;Stable snapshot&lt;/a&gt; (Wed Apr 12 04:01:43 JST 2006) is available. This is tar'ed and gzip'ed file of the latest stable CVS. It should be better than the last stable release.&lt;/li&gt;&lt;li&gt;&lt;a href="ftp://ftp.ruby-lang.org/pub/ruby/snapshot.tar.gz"&gt;Nightly snapshot&lt;/a&gt; (Wed Apr 12 04:00:49 JST 2006) is available. This is tar'ed and gzip'ed file of the latest CVS. It may contain unfixed problems. (as usual ;-)&lt;/li&gt;&lt;li&gt;&lt;a href="ftp://ftp.ruby-lang.org/pub/ruby/snapshot-1.6.tar.gz"&gt;1.6 snapshot&lt;/a&gt; (Wed Apr 12 04:02:19 JST 2006) is available. This is tar'ed and gzip'ed file of the latest 1.6 CVS. If you cannot shift to 1.8 for some reasons and you want better version than last 1.6 release, use this snapshot.&lt;/li&gt;&lt;li&gt;You can get &lt;a href="http://www.garbagecollect.jp/ruby/mswin32/"&gt;Ruby-mswin32 &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt;.&lt;/li&gt;&lt;li&gt;&lt;a href="http://rubyinstaller.rubyforge.org/wiki/wiki.pl"&gt;Install Ruby under Windows &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; ... A single download that contains everything you need to run Ruby under various Windows operating systems.&lt;/li&gt;&lt;li&gt;&lt;a href="http://www.ruby-lang.org/%7Eeban/ruby/binaries/"&gt;Ruby on Windows&lt;/a&gt; (cygwin setup, djgpp, mingw)&lt;/li&gt;&lt;/ul&gt; &lt;h3&gt;FTP Mirrors&lt;/h3&gt; &lt;ul&gt;&lt;li&gt;&lt;a href="ftp://core.ring.gr.jp/pub/lang/ruby/"&gt;Japan 1 &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; and &lt;a href="http://www.t.ring.gr.jp/"&gt;the mirror sites &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (RingServer)&lt;/li&gt;&lt;li&gt;&lt;a href="ftp://ftp.iij.ad.jp/pub/lang/ruby/"&gt;Japan 2 &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (IIJ)&lt;/li&gt;&lt;li&gt;&lt;a href="ftp://ftp.idaemons.org/pub/mirror/ftp.ruby-lang.org/ruby/"&gt;Japan 3 &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (idaemons.org)&lt;/li&gt;&lt;li&gt;&lt;a href="ftp://ftp.ruby-lang.org/pub/ruby/"&gt;Japan 4&lt;/a&gt; (master) - slow&lt;/li&gt;&lt;li&gt;&lt;a href="ftp://ftp.kr.freebsd.org/pub/ruby/"&gt;Korea &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (Korea FreeBSD Users Group)&lt;/li&gt;&lt;li&gt;&lt;a href="ftp://ftp.fu-berlin.de/unix/languages/ruby/"&gt;Germany &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (FU Berlin)&lt;/li&gt;&lt;li&gt;&lt;a href="ftp://ftp.easynet.be/ruby/"&gt;Belgium &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (Easynet)&lt;/li&gt;&lt;li&gt;&lt;a href="ftp://ftp.chg.ru/pub/lang/ruby/"&gt;Russia &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (ChgNet)&lt;/li&gt;&lt;li&gt;&lt;a href="ftp://ftp.mirror.ac.uk/mirror/ftp.ruby-lang.org/pub/ruby/"&gt;UK &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (mirror.ac.uk)&lt;/li&gt;&lt;li&gt;&lt;a href="ftp://ftp.ntua.gr/pub/lang/ruby/"&gt;Greece &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (National Technical University of Athens)&lt;/li&gt;&lt;li&gt;&lt;a href="ftp://sunsite.dk/mirrors/ruby/"&gt;Denmark &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (sunsite.dk)&lt;/li&gt;&lt;li&gt;&lt;a href="ftp://xyz.lcs.mit.edu/pub/ruby/"&gt;United States 1 &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (lcs.mit.edu)&lt;/li&gt;&lt;li&gt;&lt;a href="ftp://www.ibiblio.org/pub/languages/ruby/"&gt;United States 2 &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (ibiblio.org)&lt;/li&gt;&lt;li&gt;&lt;a href="ftp://gd.tuwien.ac.at/languages/ruby/"&gt;Austria &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (tuwien.ac.at)&lt;/li&gt;&lt;li&gt;&lt;a href="ftp://ftp.isu.edu.tw/pub/Unix/Lang/Ruby/"&gt;Taiwan 1 &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (isu.edu.tw)&lt;/li&gt;&lt;li&gt;&lt;a href="ftp://ftp.cs.pu.edu.tw/Unix/lang/Ruby/"&gt;Taiwan 2 &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (ftp.cs.pu.edu.tw)&lt;/li&gt;&lt;li&gt;&lt;a href="ftp://mirror.cs.mun.ca/pub/mirror/ruby/"&gt;Canada &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (mirror.cs.mun.ca)&lt;/li&gt;&lt;/ul&gt; &lt;h3&gt;HTTP Mirrors&lt;/h3&gt; &lt;ul&gt;&lt;li&gt;&lt;a href="http://core.ring.gr.jp/archives/lang/ruby/"&gt;Japan &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; and &lt;a href="http://www.t.ring.gr.jp/"&gt;the mirror sites &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (RingServer)&lt;/li&gt;&lt;li&gt;&lt;a href="http://mirrors.sunsite.dk/ruby/"&gt;Denmark &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (sunsite.dk)&lt;/li&gt;&lt;li&gt;&lt;a href="http://www.xs4all.nl/%7Ehipster/lib/mirror/ruby/"&gt;The Netherlands &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (XS4ALL) - releases only&lt;/li&gt;&lt;li&gt;&lt;a href="http://xyz.lcs.mit.edu/ruby/"&gt;United States 1 &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (lcs.mit.edu)&lt;/li&gt;&lt;li&gt;&lt;a href="http://www.ibiblio.org/pub/languages/ruby/"&gt;United States 2 &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (ibiblio.org)&lt;/li&gt;&lt;li&gt;&lt;a href="http://www.binarycode.org/ruby/"&gt;United States 3 &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (binarycode.org)&lt;/li&gt;&lt;li&gt;&lt;a href="http://www.online-mirror.org/ruby/"&gt;United States 4 &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (online-mirror.org)&lt;/li&gt;&lt;li&gt;&lt;a href="http://ruby.trexle.com/"&gt;United States 5 &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (trexle.com)&lt;/li&gt;&lt;li&gt;&lt;a href="http://www.mirror.ac.uk/mirror/ftp.ruby-lang.org/pub/ruby"&gt;UK &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (mirror.ac.uk)&lt;/li&gt;&lt;li&gt;&lt;a href="http://gd.tuwien.ac.at/languages/ruby/"&gt;Austria &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (tuwien.ac.at)&lt;/li&gt;&lt;li&gt;&lt;a href="http://ftp.isu.edu.tw/pub/Unix/Lang/Ruby/"&gt;Taiwan 1 &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (isu.edu.tw)&lt;/li&gt;&lt;li&gt;&lt;a href="http://ftp.cs.pu.edu.tw/Unix/lang/Ruby/"&gt;Taiwan 2 &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (ftp.cs.pu.edu.tw)&lt;/li&gt;&lt;li&gt;&lt;a href="http://ruby.paracoda.com/"&gt;Canada &lt;img class="ext" src="http://www.ruby-lang.org/ext.png" alt="" height="9" width="9" /&gt;&lt;/a&gt; (paracoda.com)&lt;/li&gt;&lt;/ul&gt; &lt;h3&gt;Rsync Mirrors&lt;/h3&gt; &lt;ul&gt;&lt;li&gt;Denmark: rsync://sunsite.dk/ftp/mirrors/ruby/ &lt;/li&gt;&lt;li&gt;Japan: rsync://rsync.idaemons.org/ftp/mirror/ftp.ruby-lang.org/ruby/ &lt;/li&gt;&lt;li&gt;Austria: rsync://gd.tuwien.ac.at/languages/ruby/&lt;/li&gt;&lt;li&gt;Canada: rsync://mirror.cs.mun.ca/ruby/&lt;/li&gt;&lt;li&gt;Taiwan: rsync://ftp.cs.pu.edu.tw/Ruby/&lt;/li&gt;&lt;/ul&gt; &lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/25952467-114484809104007349?l=khmerruby.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://khmerruby.blogspot.com/feeds/114484809104007349/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=25952467&amp;postID=114484809104007349' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/25952467/posts/default/114484809104007349'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/25952467/posts/default/114484809104007349'/><link rel='alternate' type='text/html' href='http://khmerruby.blogspot.com/2006/04/download-ruby.html' title='Download Ruby'/><author><name>Socheat Yi</name><uri>http://www.blogger.com/profile/00716074929906192408</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://userpics-27.hi5.com/userpics/927/668/66878927.img.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-25952467.post-114484803290261905</id><published>2006-04-12T06:20:00.000-07:00</published><updated>2006-04-12T06:20:39.130-07:00</updated><title type='text'>What's Ruby?</title><content type='html'>&lt;div class="section"&gt; &lt;p&gt;Ruby is the interpreted scripting language for quick and easy object-oriented programming. It has many features to process text files and to do system management tasks (as in Perl). It is simple, straight-forward, extensible, and portable.&lt;/p&gt; &lt;p&gt;Oh, I need to mention, it's totally free, which means not only free of charge, but also freedom to use, copy, modify, and distribute it.&lt;/p&gt; &lt;h3&gt;Features of Ruby&lt;/h3&gt; &lt;ul&gt;&lt;li&gt;Ruby has simple syntax, partially inspired by Eiffel and Ada.&lt;/li&gt;&lt;li&gt;Ruby has exception handling features, like Java or Python, to make it easy to handle errors.&lt;/li&gt;&lt;li&gt;Ruby's operators are syntax sugar for the methods. You can redefine them easily.&lt;/li&gt;&lt;li&gt;Ruby is a complete, full, pure object oriented language: OOL. This means all data in Ruby is an object, in the sense of Smalltalk: no exceptions. Example: In Ruby, the number 1 is an instance of class Fixnum.&lt;/li&gt;&lt;li&gt;Ruby's OO is carefully designed to be both complete and open for improvements. Example: Ruby has the ability to add methods to a class, or even to an instance during runtime. So, if needed, an instance of one class *can* behave differently from other instances of the same class.&lt;/li&gt;&lt;li&gt;Ruby features single inheritance only, *on purpose*. But Ruby knows the concept of modules (called Categories in Objective-C). Modules are collections of methods. Every class can import a module and so gets all its methods for free. Some of us think that this is a much clearer way than multiple inheritance, which is complex, and not used very often compared with single inheritance (don't count C++ here, as it has often no other choice due to strong type checking!).&lt;/li&gt;&lt;li&gt;Ruby features true closures. Not just unnamed function, but with present variable bindings.&lt;/li&gt;&lt;li&gt;Ruby features blocks in its syntax (code surrounded by '{' ... '}' or 'do' ... 'end'). These blocks can be passed to methods, or converted into closures.&lt;/li&gt;&lt;li&gt;Ruby features a true mark-and-sweep garbage collector. It works with all Ruby objects. You don't have to care about maintaining reference counts in extension libraries. This is better for your health. ;-)&lt;/li&gt;&lt;li&gt;Writing C extensions in Ruby is easier than in Perl or Python, due partly to the garbage collector, and partly to the fine extension API. SWIG interface is also available.&lt;/li&gt;&lt;li&gt;Integers in Ruby can (and should) be used without counting their internal representation. There *are* small integers (instances of class Fixnum) and large integers (Bignum), but you need not worry over which one is used currently. If a value is small enough, an integer is a Fixnum, otherwise it is a Bignum. Conversion occurs automatically.&lt;/li&gt;&lt;li&gt;Ruby needs no variable declarations. It uses simple naming conventions to denote the scope of variables. Examples: simple 'var' = local variable, '@var' = instance variable, '$var' = global variable. So it is also not necessary to use a tiresome 'self.' prepended to every instance member.&lt;/li&gt;&lt;li&gt;Ruby can load extension libraries dynamically if an OS allows.&lt;/li&gt;&lt;li&gt;Ruby features OS independent threading. Thus, for all platforms on which Ruby runs, you also have multithreading, regardless of if the OS supports it or not, even on MS-DOS! ;-)&lt;/li&gt;&lt;li&gt;Ruby is highly portable: it is developed mostly on Linux, but works on many types of UNIX, DOS, Windows 95/98/Me/NT/2000/XP, MacOS, BeOS, OS/2, etc.&lt;/li&gt;&lt;/ul&gt; &lt;h3&gt;The Creator of Ruby&lt;/h3&gt; &lt;p&gt;Yukihiro Matsumoto, a.k.a Matz &lt;a href="mailto:matz@netlab.jp"&gt;matz@netlab.jp&lt;/a&gt;&lt;/p&gt; &lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/25952467-114484803290261905?l=khmerruby.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://khmerruby.blogspot.com/feeds/114484803290261905/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=25952467&amp;postID=114484803290261905' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/25952467/posts/default/114484803290261905'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/25952467/posts/default/114484803290261905'/><link rel='alternate' type='text/html' href='http://khmerruby.blogspot.com/2006/04/whats-ruby.html' title='What&apos;s Ruby?'/><author><name>Socheat Yi</name><uri>http://www.blogger.com/profile/00716074929906192408</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://userpics-27.hi5.com/userpics/927/668/66878927.img.jpg'/></author><thr:total>0</thr:total></entry></feed>
