Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Web Applications & You

Web Applications & You

A really simple intro to rails I presented to a high school CS class

Will Cosgrove

March 26, 2012
Tweet

Other Decks in Programming

Transcript

  1. dynamic websites are • different for each user • usually

    database backed • usually have a way to log in
  2. pick a framework, any framework • Ruby on Rails •

    Django • CakePHP • Sinatra • Play!
  3. models map to the database posts id title body created_at

    1 2 3 test lorem hello this i... ipsum world 03-25-12 03-26-12 03-26-12 database columns become instance variables with getter and setter methods
  4. views are what the user sees the default template language

    is ERB (embedded ruby), which is a superset of HTML
  5. views are what the user sees <%= titleize @post.title %>

    <% @post.each do |post| %> ... <% end %>
  6. resources for learning more • RailsCasts (railscasts.com) • Rails for

    Zombies (railsforzombies.com) • PeepCode (peepcode.com) • Pragmatic Programmer (pragprog.com)