SlideShare a Scribd company logo
Programming, !
Web Applications !
and Ruby on Rails
Marco Schaden!
@donschado
Saturday 24th May 2014
Buzzwords!
Web Application
Ruby
Rails
Programming
HTTP
MVC
Model
View
Controller
Request
Response
Server
Protocol
?
?
?
?
?
?
?
HTML
all the stuff in 30 minutes
<<Programming>>
Rails Girls: Programming, Web Applications and Ruby on Rails
"It’s a boy’s thing"
http://en.wikipedia.org/wiki/Women_in_computing
http://en.wikipedia.org/wiki/Women_in_computing
"You need a Ph.D. in mathematics"
Not necessarily, but…
communication:
express your thoughts!
and ideas properly
passion:
care about what you’re doing !
and be curious how things work
research:
read documentation, !
consult others or!
just google it!
problem solving:
read the error messages !
and be hungry to solve issues
+ patience
Rails Girls: Programming, Web Applications and Ruby on Rails
programming: !
!
is telling a computer what to do!
!
(no magic involved)
step-by-step instructions
= program
3.times0do0
0 print0"Hello0World!"0
end
Ruby
A PROGRAMMER’S BEST FRIEND
https://www.ruby-lang.org/
imagine all the programming languages
Ruby
Why Ruby?
Yukihiro Matsumoto !
(Matz)
Ruby is designed to be human-
oriented. It reduces the burden of
programming. It tries to push jobs
back to machines.!
!
You can accomplish more tasks
with less work, in smaller yet
readable code.
"Matz is nice so we are nice"
Later we will learn more about Ruby…
Web Application
?
"A web application is a program that is displayed in a web browser. *
Web applications are usually stored (and executed) on a web server.
They can be accessed through the Internet 

via a communication protocol such as HTTP. " 

– Wikipedia
HTTP?
HyperTextTransfer Protocol
http://weheartit.com/entry/17157559
HTTP
Request Cycle
In 4 Easy Steps
(or how the internet works)
your computer!
running a browser of your choice
a web server !
somewhere on the internet!
running a web application
Hey$can$I$get$the$
railsgirls$website?
1
http://railsgirls.com/cologne
Hey$can$I$get$the$
railsgirls$website?
http$request$
get,$post,$put,$delete,…
1
let$me$check…$.
2
$ok,$here$it$is
http$response$
generated$data,$HTML,$static$files,$images,…
3
4
Yay!
GOT IT!
Rails Girls: Programming, Web Applications and Ruby on Rails
David Heinemeier Hansson!
(DHH)
Why Rails?
Rails is an attempt to mold the
beauty and productiveness of
Ruby into a framework for
web applications.
Rails emphasizes principles such as:!
• convention over configuration!
• don't repeat yourself (DRY)!
• model - view - controller
architecture (MVC)
http://contributors.rubyonrails.org/
http://rubyonrails.org/
*over 3000 people have contributed:
MVC?
Model -View - Controller
http://weheartit.com/entry/17157559
Rails Girls: Programming, Web Applications and Ruby on Rails
Data$+$Logic
Presentation
Intermediary
WHY…?!?!
w/o MVC:
http://media0.faz.net/ppmedia/aktuell/wirtschaft/777415979/1.1528426/default/wo-ist-noch-mal-die-rechnung-ein-buero-mit-sehr-kreativem-chaos.jpg
with MVC:
http://blog.meine-moebelmanufaktur.de/wp-content/uploads/2014/02/bunte_ordner_buero.jpg
/
Example MVC Web Application
https://github.com/DonSchado/facebook-lite
/
Example MVC Web Application
Layout
View
Post
https://github.com/DonSchado/facebook-lite
URL localhost:3000/
(remember the request cycle?)
GET /!Request
Router
 get "/" => "welcome#index"!
Controller
 class WelcomeController < ApplicationController!
def index!
$$@posts0= Post.all !
end!
end!
Model
 class Post < ActiveRecord::Base!
end!
Database * create_table "posts" do |t|!
 t.text "content"!
  t.integer "user_id"!
  t.datetime "created_at"!
  t.datetime "updated_at"!
end!
Model
 class Post < ActiveRecord::Base!
end!
Controller
 class WelcomeController < ApplicationController!
def index!
$$@posts0= Post.all !
end!
end!
View
 <h1>Das neuste aus ...$</h1>!
!
<ul>$
$$<%=0@posts.each$do$|post|$%>0
!
!
!
!
!
00<%0end0%>$
</ul>$
<li>$
$$<%=$image_tag(post.user.avatar)$%>$
$$<%=$post.user.name$%>$
$$<%=$post.content$%>$
</li>
<html$lang="en">$
$$<head>$
$$$$$<title>Facebook$Lite</title>$
$$$$$<%=$stylesheet_link_tag$$$$"application",$media:$"all"$%>$
$$$$$<%=$javascript_include_tag$"application"$%>$
$$</head>$
$$<body>$
$$$$<div$class="container">$
$$$$$$<%=$yield$%>$
$$$$</div>$
$$</body>$
</html>
Layout

Response
(HTML)*

<html lang="en">!
<head>!
<title>Facebook Lite</title>!
<link href="/assets/application.css" media="all" rel="stylesheet">!
<script src="/assets/application.js"></script>!
</head>!
<body>!
<div>!
<h1>Das Neuste aus dem ganzen Netzwerk</h1>!
<ul>!
<li>!
<img src="https://somewhere.github.com/1062e0f.png">!
<h4>Liane<small>19 Nov 20:32</small></h4>!
<p>Ich bin hier!!!</p>!
</li>!
<li>!
<img src="https://somwhere.github.com/fa47a113f69.png">!
<h4>Marco<small>19 Nov 20:02</small></h4>!
<p>Hallo, ist da wer?</p>!
</li>!
<li>!
<img src="https://somwhere.github.com/fa47a113f69.png">!
<h4>Marco<small>19 Nov 19:02</small></h4>!
<p>Hallo Welt!</p>!
</li>!
</ul>!
</div>!
</body>!
</html>
URL localhost:3000/
http://cheezburger.com/
Response
(HTML)
Browser
Layout
View
Request
Router
Controller
Model
Database
Response
(HTML)
Browser
Layout
View
Request
Router
Controller
Model
Database
Response
(HTML)
Browser
Layout
View
Request
Router
Controller
Model
Database
Response
(HTML)
Browser
Layout
View
Request
Router
Controller
Model
Database
Response
(HTML)
Browser
Layout
View
Request
Router
Controller
Model
Database
Response
(HTML)
Browser
Layout
View
Request
Router
Controller
Model
Database
Response
(HTML)
Browser
Layout
View
Request
Router
Controller
Model
Database
Response
(HTML)
Browser
Layout
View
Request
Router
Controller
Model
Database
Response
(HTML)
Browser
Layout
View
Request
Router
Controller
Model
Database
Response
(HTML)
Browser
Layout
View
Request
Router
Controller
Model
Database
Response
(HTML)
Browser
Layout
View
Request
Router
Controller
Model
Database
Response
(HTML)
Browser
Layout
View
Request
Router
Controller
Model
Database
All The Tools You Need:
AText Editor for writing code and editing files.
TheTerminal (known as Command Prompt)!
Where you start the rails server and run commands.
A Web Browser (Firefox, Safari, Chrome,…) 

for viewing and interacting with your application.
Ruby, the amazing programming language we love
Rails, the framework for building web applications
Conclusion
we’ve learned a lot of new stuff
http$response$
generated$data,$HTML,$static$files,$images,…
http$request$
get,$post,$put,$delete,…
Have fun!!
Enjoy your workshop!!
Ask the coaches!
http://tryruby.org
Now let’s start coding!
1
http://guides.railsgirls.com/app2

More Related Content

What's hot (20)

PPTX
JavaScript Performance Patterns
Stoyan Stefanov
 
PDF
Ugo Cei Presentation
RubyOnRails_dude
 
PDF
Node.js & Twitter Bootstrap Crash Course
Aaron Silverman
 
PPTX
High Performance Social Plugins
Stoyan Stefanov
 
PDF
How to make Ajax work for you
Simon Willison
 
PDF
Progressive Downloads and Rendering - take #2
Stoyan Stefanov
 
PDF
JavaScript Web Workers
Tobias Pfeiffer
 
PDF
WP Weekend #2 - Corcel, aneb WordPress přes Laravel
Brilo Team
 
PPTX
JavaScript performance patterns
Stoyan Stefanov
 
PPTX
Ruby On Grape
Andrii Furmanets
 
PDF
Consegi 2010 - Dicas de Desenvolvimento Web com Ruby
Fabio Akita
 
PDF
Web workers
Surbhi Mathur
 
PDF
Grand Rapids PHP Meetup: Behavioral Driven Development with Behat
Ryan Weaver
 
KEY
Sinatra for REST services
Emanuele DelBono
 
PDF
Distributed Ruby and Rails
Wen-Tien Chang
 
PDF
Write php deploy everywhere tek11
Michelangelo van Dam
 
PPTX
webworkers
Asanka Indrajith
 
PDF
Rails for Beginners - Le Wagon
Alex Benoit
 
KEY
Getting Started with HTML 5 Web workers
Flumes
 
PDF
Fisl 11 - Dicas de Desenvolvimento Web com Ruby
Fabio Akita
 
JavaScript Performance Patterns
Stoyan Stefanov
 
Ugo Cei Presentation
RubyOnRails_dude
 
Node.js & Twitter Bootstrap Crash Course
Aaron Silverman
 
High Performance Social Plugins
Stoyan Stefanov
 
How to make Ajax work for you
Simon Willison
 
Progressive Downloads and Rendering - take #2
Stoyan Stefanov
 
JavaScript Web Workers
Tobias Pfeiffer
 
WP Weekend #2 - Corcel, aneb WordPress přes Laravel
Brilo Team
 
JavaScript performance patterns
Stoyan Stefanov
 
Ruby On Grape
Andrii Furmanets
 
Consegi 2010 - Dicas de Desenvolvimento Web com Ruby
Fabio Akita
 
Web workers
Surbhi Mathur
 
Grand Rapids PHP Meetup: Behavioral Driven Development with Behat
Ryan Weaver
 
Sinatra for REST services
Emanuele DelBono
 
Distributed Ruby and Rails
Wen-Tien Chang
 
Write php deploy everywhere tek11
Michelangelo van Dam
 
webworkers
Asanka Indrajith
 
Rails for Beginners - Le Wagon
Alex Benoit
 
Getting Started with HTML 5 Web workers
Flumes
 
Fisl 11 - Dicas de Desenvolvimento Web com Ruby
Fabio Akita
 

Viewers also liked (7)

PDF
Programming & The Web & Programming the Web
Vesa Vänskä
 
PDF
Introduction to Web Programming
Ynon Perek
 
PDF
The web and programming: an introduction - Simple, short and friendly
Alja Isakovic
 
PDF
Model View Controller (MVC)
Javier Antonio Humarán Peñuñuri
 
PPT
Mvc architecture
Surbhi Panhalkar
 
PDF
How to Make Awesome SlideShares: Tips & Tricks
SlideShare
 
PDF
Getting Started With SlideShare
SlideShare
 
Programming & The Web & Programming the Web
Vesa Vänskä
 
Introduction to Web Programming
Ynon Perek
 
The web and programming: an introduction - Simple, short and friendly
Alja Isakovic
 
Model View Controller (MVC)
Javier Antonio Humarán Peñuñuri
 
Mvc architecture
Surbhi Panhalkar
 
How to Make Awesome SlideShares: Tips & Tricks
SlideShare
 
Getting Started With SlideShare
SlideShare
 
Ad

Similar to Rails Girls: Programming, Web Applications and Ruby on Rails (20)

PDF
Finding harmony in web development
Christian Heilmann
 
PPT
Ruby On Rails Presentation
Paul Pajo
 
PDF
Ruby and Rails Basics
ArrrrCamp
 
PPTX
Web Development Today
bretticus
 
PPT
Web 2.0 for IA's
Dave Malouf
 
PDF
Week01 jan19 introductionto_php
Jeanho Chu
 
PDF
Rails & Backbone.js
Cheenu Madan
 
PDF
"The working architecture of NodeJs applications" Viktor Turskyi
Julia Cherniak
 
PDF
Stefan Judis "Did we(b development) lose the right direction?"
Fwdays
 
PDF
Web Application Intro for RailsGirls Berlin May 2013
Tobias Pfeiffer
 
PDF
Make your app idea a reality with Ruby On Rails
Nataly Tkachuk
 
PDF
Ruby on Rails best resources for self
Durga Prasad Tumu
 
PDF
Php and-mvc
Manoj Sahoo
 
PPTX
Simplicity - develop modern web apps with tiny frameworks and tools
Rui Carvalho
 
PPTX
ASP.NET MVC Presentation
Volkan Uzun
 
PDF
Introduction to Ruby on Rails
Alessandro DS
 
PPTX
Week01 jan19 introductionto_php
Jeanho Chu
 
PPTX
Doing Modern Web, aka JavaScript and HTML5 in the Enterprise NYC Code Camp
Chris Love
 
PDF
How to not create an unbreakable Rails monolith
Bruno Almeida
 
PPTX
Mvc presentation
MaslowB
 
Finding harmony in web development
Christian Heilmann
 
Ruby On Rails Presentation
Paul Pajo
 
Ruby and Rails Basics
ArrrrCamp
 
Web Development Today
bretticus
 
Web 2.0 for IA's
Dave Malouf
 
Week01 jan19 introductionto_php
Jeanho Chu
 
Rails & Backbone.js
Cheenu Madan
 
"The working architecture of NodeJs applications" Viktor Turskyi
Julia Cherniak
 
Stefan Judis "Did we(b development) lose the right direction?"
Fwdays
 
Web Application Intro for RailsGirls Berlin May 2013
Tobias Pfeiffer
 
Make your app idea a reality with Ruby On Rails
Nataly Tkachuk
 
Ruby on Rails best resources for self
Durga Prasad Tumu
 
Php and-mvc
Manoj Sahoo
 
Simplicity - develop modern web apps with tiny frameworks and tools
Rui Carvalho
 
ASP.NET MVC Presentation
Volkan Uzun
 
Introduction to Ruby on Rails
Alessandro DS
 
Week01 jan19 introductionto_php
Jeanho Chu
 
Doing Modern Web, aka JavaScript and HTML5 in the Enterprise NYC Code Camp
Chris Love
 
How to not create an unbreakable Rails monolith
Bruno Almeida
 
Mvc presentation
MaslowB
 
Ad

More from DonSchado (6)

PDF
The return of an old enemy
DonSchado
 
PDF
Decorator & Presenter Design Pattern
DonSchado
 
PDF
Ruby's require, autoload and load methods
DonSchado
 
PDF
A taste of Computer Science
DonSchado
 
PDF
Mutation testing with the mutant gem
DonSchado
 
PDF
Rails - How does it work?
DonSchado
 
The return of an old enemy
DonSchado
 
Decorator & Presenter Design Pattern
DonSchado
 
Ruby's require, autoload and load methods
DonSchado
 
A taste of Computer Science
DonSchado
 
Mutation testing with the mutant gem
DonSchado
 
Rails - How does it work?
DonSchado
 

Recently uploaded (20)

PDF
POV_ Why Enterprises Need to Find Value in ZERO.pdf
darshakparmar
 
PDF
New from BookNet Canada for 2025: BNC BiblioShare - Tech Forum 2025
BookNet Canada
 
PDF
The Rise of AI and IoT in Mobile App Tech.pdf
IMG Global Infotech
 
PPTX
COMPARISON OF RASTER ANALYSIS TOOLS OF QGIS AND ARCGIS
Sharanya Sarkar
 
PDF
CIFDAQ Market Insights for July 7th 2025
CIFDAQ
 
PPTX
"Autonomy of LLM Agents: Current State and Future Prospects", Oles` Petriv
Fwdays
 
PPTX
From Sci-Fi to Reality: Exploring AI Evolution
Svetlana Meissner
 
PDF
Exolore The Essential AI Tools in 2025.pdf
Srinivasan M
 
PPTX
MuleSoft MCP Support (Model Context Protocol) and Use Case Demo
shyamraj55
 
PDF
Jak MŚP w Europie Środkowo-Wschodniej odnajdują się w świecie AI
dominikamizerska1
 
DOCX
Python coding for beginners !! Start now!#
Rajni Bhardwaj Grover
 
PDF
The 2025 InfraRed Report - Redpoint Ventures
Razin Mustafiz
 
PPTX
OpenID AuthZEN - Analyst Briefing July 2025
David Brossard
 
PDF
Transcript: Book industry state of the nation 2025 - Tech Forum 2025
BookNet Canada
 
PDF
How do you fast track Agentic automation use cases discovery?
DianaGray10
 
PPTX
The Project Compass - GDG on Campus MSIT
dscmsitkol
 
PDF
LOOPS in C Programming Language - Technology
RishabhDwivedi43
 
PDF
Peak of Data & AI Encore AI-Enhanced Workflows for the Real World
Safe Software
 
PDF
Book industry state of the nation 2025 - Tech Forum 2025
BookNet Canada
 
PDF
Bitcoin for Millennials podcast with Bram, Power Laws of Bitcoin
Stephen Perrenod
 
POV_ Why Enterprises Need to Find Value in ZERO.pdf
darshakparmar
 
New from BookNet Canada for 2025: BNC BiblioShare - Tech Forum 2025
BookNet Canada
 
The Rise of AI and IoT in Mobile App Tech.pdf
IMG Global Infotech
 
COMPARISON OF RASTER ANALYSIS TOOLS OF QGIS AND ARCGIS
Sharanya Sarkar
 
CIFDAQ Market Insights for July 7th 2025
CIFDAQ
 
"Autonomy of LLM Agents: Current State and Future Prospects", Oles` Petriv
Fwdays
 
From Sci-Fi to Reality: Exploring AI Evolution
Svetlana Meissner
 
Exolore The Essential AI Tools in 2025.pdf
Srinivasan M
 
MuleSoft MCP Support (Model Context Protocol) and Use Case Demo
shyamraj55
 
Jak MŚP w Europie Środkowo-Wschodniej odnajdują się w świecie AI
dominikamizerska1
 
Python coding for beginners !! Start now!#
Rajni Bhardwaj Grover
 
The 2025 InfraRed Report - Redpoint Ventures
Razin Mustafiz
 
OpenID AuthZEN - Analyst Briefing July 2025
David Brossard
 
Transcript: Book industry state of the nation 2025 - Tech Forum 2025
BookNet Canada
 
How do you fast track Agentic automation use cases discovery?
DianaGray10
 
The Project Compass - GDG on Campus MSIT
dscmsitkol
 
LOOPS in C Programming Language - Technology
RishabhDwivedi43
 
Peak of Data & AI Encore AI-Enhanced Workflows for the Real World
Safe Software
 
Book industry state of the nation 2025 - Tech Forum 2025
BookNet Canada
 
Bitcoin for Millennials podcast with Bram, Power Laws of Bitcoin
Stephen Perrenod
 

Rails Girls: Programming, Web Applications and Ruby on Rails