Wednesday, October 14, 2009

Workshop 5

Developer’s thread

Build the web application on the Rails framework, which is the Ruby language. Using the Webrick ruby server deploys the website and creates controllers to do actions.


We create the controller and try to connect the method action of the controller. Methods will do some scripts to run on server and starting website significantly.



In the action the breathe method in the mammal controller require the template to run out the website remarkably. The necessary template, which is just a .rhtml file to control the information to show out.




This is the example to show out the necessary information o the web page with the RoR. The breathe method is called directly on the mammal controller.
Create the new application on the Rails to demonstrate the use of an active view to pass the data from an action to view.




Now, we modify the rubycode action with the value of time in the scenery controller and get the data directly from the action to show on the web page.



This is example that illustrated the convenience of the RoR to design the web page, which is less coding on the web page. The controller gets the data on its methods to show out.

The Rails’ controller can get the information from the web page to do or show on another web page of the site. This is very easy to get the information on web page, which just modify necessary variables and pass them on the method of controller.

No comments:

Post a Comment