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

Nola On Rails - #1 The Class && The Web

Nola On Rails - #1 The Class && The Web

A light covering of the undercover actions of the browser, servers, and the communication between

Kurtis Rainbolt-Greene

February 29, 2012
Tweet

More Decks by Kurtis Rainbolt-Greene

Other Decks in Programming

Transcript

  1. Welcome to NOR • This class will teach you how

    the internet works, kinda • This class will teach you how to program, kinda • This class will teach you how Rails works, kinda • This class will show you the tools of the trade • This class will show you how to build a prototype web application
  2. Who am I? • Hacker (3y), author (10y), and educator

    (5y) • Started programming with toy languages • Ruby was my first real language • Sinatra my first web framework • Rails is where the real money comes from • Since then, many other languages, Ruby still primary
  3. What you will learn • How to build a Rails

    application • Some programming concepts • The tools that are easiest to use • Some behavior driven development
  4. What this class doesn't cover • 90% of programming •

    The darker and deeper parts of the web • HTML, CSS, or JavaScript • Other languages, frameworks, or similar • Profiling, testing, or coverage • The really hard stuff
  5. What you need • A computer* • A text editor

    (Sublime Text 2, Gedit) • A web browser (Chrome, Firefox) • A terminal *A Mac is better, but realistically you can use a Windows or Linux computer.
  6. What the class provides • Each session will have a

    presentation • Each session is video recorded • Each session is audio recorded • Any code, materials, or links will be on the website: http://nolaonrails.com/courses
  7. Class time framework • Every class is 1 hour and

    15 minutes long • 5 minute discussion on what we did last class • 45 minutes on part of building a rails application • 15 minutes reviewing what we learned • 10 minutes with cleanup, problem areas, and resources
  8. What is Programming? • Making a computer do what you

    want • Usually requires writing in a programming language • Making a program read your code • The process of providing input, resolving logic, pushing output
  9. What is Ruby? • A programming language • Good for

    web development, among other things • Huge and vibrant community • Very human readable
  10. What is Rails? • A web application framework written in

    Ruby • Started in 2001 as a web app building script • The latest version is 3.2 and is widely used • Removes a lot of the boilerplate from building web applications
  11. Web Development • Building applications or services for the web

    • The client is a browser ◦ Renders HTML ◦ Styles with CSS ◦ Runs JavaScript • The server is a stack including: ◦ A HTTP Server (Apache, Nginx, Lighttpd) ◦ A daemon listening on a port (80) • The protocol is called HTTP
  12. The Browser • The browser makes requests to the server

    • Gets a response from the server • Attempts to render the response (HTML) • Styles the DOM (CSS) • Manipulates the DOM (JS) • Can (optionally) send other types of requests
  13. HTTP: GET && POST • The protocol of the internet

    • GET is for asking the server for content: "Server, can you GET me the /home resource?" • POST is for sending the server content: "Server, please take this data to /accounts/new" There are others, but are unimportant
  14. Stacks && Servers • Take requests from clients (which can

    be other servers) • Processes the request path (looks like '/xxx/vyyy/qqq` • Passes along the parameters (looks like '? key=value&key2=value2`) • Runs logic (Like a framework, Rails) • Responds with a header and body of info (usually HTML)
  15. Rails Resources • Rails Tutorial • Rails Guide • The

    Rails Forum • Railscasts • #rails
  16. Ruby Resources • Learn Ruby The Hard Way • Programming

    Ruby • The Poignant Ruby Book • Ruby Rogues Podcast • Ruby5 • The Ruby Forum • TryRuby • #ruby-lang