yesterday,I spent 2hours to study ruby on rails,how to set up the development framework,and build up an example to show the great MVC framework charm.
commands refer below:
1.install ruby
2. install rails
gem install rails --remote
gem install rails --include -dependencies
3.create a project
rails cookbook
4.run the server
ruby script\server
5.create a page(for test use)
ruby script\generate controller Aaron
## Modify the aaron_controller.rb add a function
6.create table in mysql database:ruby table:cookbooks
add modify the database.yml in config fold.
7.interact with mysql
ruby script\generate model cookbook
ruby script\generate controller cookbook
Need add the scaffold:cookbook in cookbook_controller.rb
8.run the webpage
http://localhost:3000/cookbook (CRUD)