SlideShare ist ein Scribd-Unternehmen logo
1 von 35
Downloaden Sie, um offline zu lesen
The web and
 programming:
an introduction
  Simple, short and friendly
3 basic question

What are web apps and how do they work?


What is Ruby, how is it connected to Rails?


What is Rails and what can we use it for?
How does the web work?



• Let’s take a look at an example:
 - What happens when I type
   railsgirls.com into my web browser?
(109.74.202.152)

                1) The web browser looks up the IP address of
                           the web site using DNS
           I want to
        know more about                       Wait, I need to find
           Rails Girls                     the address of the web
                                             server with that info.




Avtor fotografije: Ed Yourdon
2) The broswers sends a “GET” request
                to the server

Hey, I need info                           Just a moment
about Rails Girls                                 ...




                    HTTP request GET
                    Host: railsgirls.com
                                      j
    your computer
j




                                           host server for
                                           railsgirls.com
3) The servers respons with a web page,
              written in HTML language


                                     Aha! Found it!




                          response in
                         HTML language
                                    j
Let me see what
       tvoj računalnik
j




this looks like...                       host server for
                                         railsgirls.com
4) The web browser makes sure the web site
           is displayed correctly

                                  Ta-da!
                             Isn’t this a nice
                                web site?
So, what are we
going to work on today?




           j

        A web app for
        collecting ideas
What will the app look like
    in our browser?
Hmm... what are
  web apps?

 And what are
 web pages?
simplesushi.com
                           I want sushi!




                                                        j
           j
                                                         web page
          Octocat                          sushi.html



Photo by: melanie_hughes
sushi.html
                                         is as it is!
                                 simplesushi.com
          But ... I don’t
           eat fish ...




                                     j
j
                                      static
                        sushi.html   web page
Octocat
What about           fancysushi.com
  here? Can I get a sushi
       without fish?




j

Octocat
web app
                                                    on the server
                    What about




                                                          j
                                         fancysushi.com
               here? Can I get a sushi
                    without fish?




            j                                  Sure, Octocat,
                                               our sushi chef
          Octocat
                                                can adjust!


Photo by: iwillbehomesoon
web app
                                             on the server




                                                   j
                                  fancysushi.com




j
                                            Here’s your
Octocat           j                     personalized sushi.
                         sushi.html      Would you like a
                                          different one?
          the result is another
               web page
web app
                                        on the server




                                              j
                             fancysushi.com




j

Octocat       j
                     sushi.html

      however it is now a
     dynamic web page,
      tailored to the user
web app
      In the real world ...             on the server




                                             j
                              facebook.com




  j

 Octocat
           j

   that’s why Facebook has
different content for each of us
If we want to
build web apps ...
If we want to
build web apps ...




                           j
        We need to be able to talk to
        the sushi chef on the server
Ruby is one of the programming
languages that we can use in web apps
                                                  If you want
                                              me to do something,
                                              you’ve got to speak
                                                    Ruby!




   Other popular languages: PHP, Python, Java, ASP.NET, Perl ...
How we can use Ruby
        to talk to a computer?
As a starting point:
1) We need to have Ruby installed (Installation Party!)




2) Use Terminal or Command Prompt (Windows)
Simple example
Let’s use irb = Interactive RuBy




      “Rails Girls”
irb examples
"Rails Girls"           # strings
2+2                     # integers
2*2                     # Ruby as a simple calculator
"Rails " * 2            # multiplying a string
"Rails " + "Girls"      # combining two string
"Rails" * "Girls"       # multiplying strings doesn’t work
"Rails Girls".length    # but string do have their own useful methods
"Rails Girls".reverse
ime = "Rails Girls"     # to simplify work, we can store objects into variables
ime.length              # same method as before used on a variable, same result
ime.reverse
ime.upcase
ime.downcase
ime + ime               # variables can also be combined, just like before
Simple example
Let’s save a program into a .rb file for easy access




    Sublime Text 2                 Terminal
simple.rb


puts “Rails Girls”
ime.rb
quiz.rb
Even the big, scary dragon
                       is made out of simple Lego blocks!




Photo by: themickeyd
Bonus tip: learn programming
            at home with:



       http://tryruby.org
http://www.codeschool.com



                            http://www.codecademy.com
What about Rails?



    Rails = Ruby on Rails = RoR
= a framework, which makes sure we can
  easily use Ruby to build web apps
    = fast rails for Ruby on the web
We’ll build today’s app
     with Rails ...
... the app will be made with different text
    files with Ruby, HTML and other code
Rails* apps have three basic
                           building blocks
                           MVC architecture = Model | View | Controller




                                     Controller = sushi chef
                                     accepts requests, makes all parts
                                             work as a whole

  Model = ingredients
     represents database data                                                  View = sushi
                                                                         the representation of the result,
* And a lot of other web apps in different languages                              seen by users
Photo by: Michael Kappel
Confused? No worries :)

           When programming:
           • Googling is a must;
           • copy-paste a valid method;
           • getting a working result
             is what really matters.

           P.S.: Practice makes perfect!
Let’s warm up before we make our own app:
     getting to know web technologies!


                      My Bentobox                             Application:              Designed by:




                       Storage                            Logic
                       Backend.                            Backend.
                       How the application stores data.    How the application works.




                                                          Style and structure
                                                          Frontend.
                                                          How the application looks.


                       Infrastructure
                       Backend.
                       How the application runs.

Weitere ähnliche Inhalte

Andere mochten auch

La gouvernance du web
La gouvernance du webLa gouvernance du web
La gouvernance du webcdicuvier
 
Histoire et sociologie du numérique, chapitre 1
Histoire et sociologie du numérique, chapitre 1Histoire et sociologie du numérique, chapitre 1
Histoire et sociologie du numérique, chapitre 1Julien PIERRE
 
Why we need to talk about women and technology?
Why we need to talk about women and technology?Why we need to talk about women and technology?
Why we need to talk about women and technology?Maria Clara Santana
 
Introduction of Programming language
Introduction of Programming languageIntroduction of Programming language
Introduction of Programming languagenasa9084
 
Introduction to Web Programming
Introduction to Web ProgrammingIntroduction to Web Programming
Introduction to Web ProgrammingYnon Perek
 
Rails Girls: Not Only for Girls - RubyKaigi 2014
Rails Girls: Not Only for Girls - RubyKaigi 2014Rails Girls: Not Only for Girls - RubyKaigi 2014
Rails Girls: Not Only for Girls - RubyKaigi 2014Emma Haruka Iwao
 
What makes AWS invincible? from JAWS Days 2014
What makes AWS invincible? from JAWS Days 2014What makes AWS invincible? from JAWS Days 2014
What makes AWS invincible? from JAWS Days 2014Emma Haruka Iwao
 
Introduction to R Programming
Introduction to R ProgrammingIntroduction to R Programming
Introduction to R Programmingizahn
 
software engineering notes for cse/it fifth semester
software engineering notes for cse/it fifth semestersoftware engineering notes for cse/it fifth semester
software engineering notes for cse/it fifth semesterrajesh199155
 
Introduction to Programming Languages
Introduction to Programming LanguagesIntroduction to Programming Languages
Introduction to Programming Languageseducationfront
 
Programming languages
Programming languagesProgramming languages
Programming languagesAsmasum
 
Lect 1. introduction to programming languages
Lect 1. introduction to programming languagesLect 1. introduction to programming languages
Lect 1. introduction to programming languagesVarun Garg
 
Cours informatique internet - 7ème (2011-2012)
Cours   informatique internet - 7ème (2011-2012)  Cours   informatique internet - 7ème (2011-2012)
Cours informatique internet - 7ème (2011-2012) Tunisie collège
 
The Internet Presentation
The Internet Presentation The Internet Presentation
The Internet Presentation guest9e3d59
 

Andere mochten auch (20)

La gouvernance du web
La gouvernance du webLa gouvernance du web
La gouvernance du web
 
Histoire et sociologie du numérique, chapitre 1
Histoire et sociologie du numérique, chapitre 1Histoire et sociologie du numérique, chapitre 1
Histoire et sociologie du numérique, chapitre 1
 
Eap et Internet 2.0
Eap et Internet 2.0Eap et Internet 2.0
Eap et Internet 2.0
 
Why we need to talk about women and technology?
Why we need to talk about women and technology?Why we need to talk about women and technology?
Why we need to talk about women and technology?
 
Introduction of Programming language
Introduction of Programming languageIntroduction of Programming language
Introduction of Programming language
 
Introduction to Web Programming
Introduction to Web ProgrammingIntroduction to Web Programming
Introduction to Web Programming
 
Rails Girls: Not Only for Girls - RubyKaigi 2014
Rails Girls: Not Only for Girls - RubyKaigi 2014Rails Girls: Not Only for Girls - RubyKaigi 2014
Rails Girls: Not Only for Girls - RubyKaigi 2014
 
What makes AWS invincible? from JAWS Days 2014
What makes AWS invincible? from JAWS Days 2014What makes AWS invincible? from JAWS Days 2014
What makes AWS invincible? from JAWS Days 2014
 
Introduction to programming
Introduction to programmingIntroduction to programming
Introduction to programming
 
Internet Presentation
Internet PresentationInternet Presentation
Internet Presentation
 
Introduction to R Programming
Introduction to R ProgrammingIntroduction to R Programming
Introduction to R Programming
 
Introduction to-programming
Introduction to-programmingIntroduction to-programming
Introduction to-programming
 
Model View Controller (MVC)
Model View Controller (MVC)Model View Controller (MVC)
Model View Controller (MVC)
 
software engineering notes for cse/it fifth semester
software engineering notes for cse/it fifth semestersoftware engineering notes for cse/it fifth semester
software engineering notes for cse/it fifth semester
 
Mvc architecture
Mvc architectureMvc architecture
Mvc architecture
 
Introduction to Programming Languages
Introduction to Programming LanguagesIntroduction to Programming Languages
Introduction to Programming Languages
 
Programming languages
Programming languagesProgramming languages
Programming languages
 
Lect 1. introduction to programming languages
Lect 1. introduction to programming languagesLect 1. introduction to programming languages
Lect 1. introduction to programming languages
 
Cours informatique internet - 7ème (2011-2012)
Cours   informatique internet - 7ème (2011-2012)  Cours   informatique internet - 7ème (2011-2012)
Cours informatique internet - 7ème (2011-2012)
 
The Internet Presentation
The Internet Presentation The Internet Presentation
The Internet Presentation
 

Ähnlich wie The web and programming: an introduction - Simple, short and friendly

Workshop Intro: FrontEnd General Overview
Workshop Intro: FrontEnd General OverviewWorkshop Intro: FrontEnd General Overview
Workshop Intro: FrontEnd General OverviewVisual Engineering
 
Coffeescript unfancy javascript
Coffeescript unfancy javascriptCoffeescript unfancy javascript
Coffeescript unfancy javascriptDimitris Tsironis
 
Isomorphic web application
Isomorphic web applicationIsomorphic web application
Isomorphic web applicationOliver N
 
In Pursuit of the Holy Grail: Building Isomorphic JavaScript Apps
In Pursuit of the Holy Grail: Building Isomorphic JavaScript AppsIn Pursuit of the Holy Grail: Building Isomorphic JavaScript Apps
In Pursuit of the Holy Grail: Building Isomorphic JavaScript AppsSpike Brehm
 
Culerity - Headless full stack testing for JavaScript
Culerity - Headless full stack testing for JavaScriptCulerity - Headless full stack testing for JavaScript
Culerity - Headless full stack testing for JavaScriptThilo Utke
 
Why you should build your own JS Frontend Framework
Why you should build your own JS Frontend FrameworkWhy you should build your own JS Frontend Framework
Why you should build your own JS Frontend Frameworkbaccigalupi
 
Introducing Japanese Cool Web Services
Introducing Japanese Cool Web ServicesIntroducing Japanese Cool Web Services
Introducing Japanese Cool Web ServicesEiji Sakai
 
Isomorphic javascript - Uppsala.js #8
Isomorphic javascript - Uppsala.js #8Isomorphic javascript - Uppsala.js #8
Isomorphic javascript - Uppsala.js #8Alexander Aivars
 
End to-End CoffeeScript
End to-End CoffeeScriptEnd to-End CoffeeScript
End to-End CoffeeScriptTrevorBurnham
 
Notes (2012-06-08)
Notes (2012-06-08)Notes (2012-06-08)
Notes (2012-06-08)Chris Pitt
 
EuRuKo JRuby Talk 2008
EuRuKo JRuby Talk 2008EuRuKo JRuby Talk 2008
EuRuKo JRuby Talk 2008geraldbauer
 
Mobile Monday - March 7th, 2011
Mobile Monday - March 7th, 2011Mobile Monday - March 7th, 2011
Mobile Monday - March 7th, 2011Ciprian Borodescu
 
BlackBerry 10 Browser
BlackBerry 10 BrowserBlackBerry 10 Browser
BlackBerry 10 BrowserErik Johnson
 
Javascript beginner-handbook
Javascript beginner-handbookJavascript beginner-handbook
Javascript beginner-handbookFaina Fridman
 
javascript-beginner-handbook.pdf
javascript-beginner-handbook.pdfjavascript-beginner-handbook.pdf
javascript-beginner-handbook.pdfRaviKumar76265
 
Building native apps with web components
Building native apps with web componentsBuilding native apps with web components
Building native apps with web componentsDenis Radin
 

Ähnlich wie The web and programming: an introduction - Simple, short and friendly (20)

Workshop Intro: FrontEnd General Overview
Workshop Intro: FrontEnd General OverviewWorkshop Intro: FrontEnd General Overview
Workshop Intro: FrontEnd General Overview
 
Coffeescript unfancy javascript
Coffeescript unfancy javascriptCoffeescript unfancy javascript
Coffeescript unfancy javascript
 
Isomorphic web application
Isomorphic web applicationIsomorphic web application
Isomorphic web application
 
In Pursuit of the Holy Grail: Building Isomorphic JavaScript Apps
In Pursuit of the Holy Grail: Building Isomorphic JavaScript AppsIn Pursuit of the Holy Grail: Building Isomorphic JavaScript Apps
In Pursuit of the Holy Grail: Building Isomorphic JavaScript Apps
 
Culerity - Headless full stack testing for JavaScript
Culerity - Headless full stack testing for JavaScriptCulerity - Headless full stack testing for JavaScript
Culerity - Headless full stack testing for JavaScript
 
Why you should build your own JS Frontend Framework
Why you should build your own JS Frontend FrameworkWhy you should build your own JS Frontend Framework
Why you should build your own JS Frontend Framework
 
HealthyCodeMay2014
HealthyCodeMay2014HealthyCodeMay2014
HealthyCodeMay2014
 
Intro to Rails
Intro to RailsIntro to Rails
Intro to Rails
 
Introducing Japanese Cool Web Services
Introducing Japanese Cool Web ServicesIntroducing Japanese Cool Web Services
Introducing Japanese Cool Web Services
 
Concurrency in ruby
Concurrency in rubyConcurrency in ruby
Concurrency in ruby
 
Isomorphic javascript - Uppsala.js #8
Isomorphic javascript - Uppsala.js #8Isomorphic javascript - Uppsala.js #8
Isomorphic javascript - Uppsala.js #8
 
End to-End CoffeeScript
End to-End CoffeeScriptEnd to-End CoffeeScript
End to-End CoffeeScript
 
Notes (2012-06-08)
Notes (2012-06-08)Notes (2012-06-08)
Notes (2012-06-08)
 
EuRuKo JRuby Talk 2008
EuRuKo JRuby Talk 2008EuRuKo JRuby Talk 2008
EuRuKo JRuby Talk 2008
 
Ruby On Rails
Ruby On RailsRuby On Rails
Ruby On Rails
 
Mobile Monday - March 7th, 2011
Mobile Monday - March 7th, 2011Mobile Monday - March 7th, 2011
Mobile Monday - March 7th, 2011
 
BlackBerry 10 Browser
BlackBerry 10 BrowserBlackBerry 10 Browser
BlackBerry 10 Browser
 
Javascript beginner-handbook
Javascript beginner-handbookJavascript beginner-handbook
Javascript beginner-handbook
 
javascript-beginner-handbook.pdf
javascript-beginner-handbook.pdfjavascript-beginner-handbook.pdf
javascript-beginner-handbook.pdf
 
Building native apps with web components
Building native apps with web componentsBuilding native apps with web components
Building native apps with web components
 

Mehr von Alja Isakovic

Starting a business as engineers: algorithms aren't everything
Starting a business as engineers: algorithms aren't everythingStarting a business as engineers: algorithms aren't everything
Starting a business as engineers: algorithms aren't everythingAlja Isakovic
 
Zakaj moraš med razvojem produkta razmišljati kot obsedeni bivši?
Zakaj moraš med razvojem produkta razmišljati kot obsedeni bivši?Zakaj moraš med razvojem produkta razmišljati kot obsedeni bivši?
Zakaj moraš med razvojem produkta razmišljati kot obsedeni bivši?Alja Isakovic
 
IoT Design Manifesto: smernice za bolj odgovoren razvoj IoT izdelkov in storitev
IoT Design Manifesto: smernice za bolj odgovoren razvoj IoT izdelkov in storitevIoT Design Manifesto: smernice za bolj odgovoren razvoj IoT izdelkov in storitev
IoT Design Manifesto: smernice za bolj odgovoren razvoj IoT izdelkov in storitevAlja Isakovic
 
Kako slike mačk pridejo na tvoj računalnik? Kratek, enostaven in mačje obarva...
Kako slike mačk pridejo na tvoj računalnik? Kratek, enostaven in mačje obarva...Kako slike mačk pridejo na tvoj računalnik? Kratek, enostaven in mačje obarva...
Kako slike mačk pridejo na tvoj računalnik? Kratek, enostaven in mačje obarva...Alja Isakovic
 
Quantified Self: The what, the why and the brave new future
Quantified Self: The what, the why and the brave new futureQuantified Self: The what, the why and the brave new future
Quantified Self: The what, the why and the brave new futureAlja Isakovic
 
def hire_more_women_in_tech(you):
def hire_more_women_in_tech(you):def hire_more_women_in_tech(you):
def hire_more_women_in_tech(you):Alja Isakovic
 
Git your Jekyll on - WebCamp Ljubljana 2015
Git your Jekyll on - WebCamp Ljubljana 2015Git your Jekyll on - WebCamp Ljubljana 2015
Git your Jekyll on - WebCamp Ljubljana 2015Alja Isakovic
 
Uvod v internet in programiranje: Enostavno, kratko in prijazno
Uvod v internet in programiranje: Enostavno, kratko in prijaznoUvod v internet in programiranje: Enostavno, kratko in prijazno
Uvod v internet in programiranje: Enostavno, kratko in prijaznoAlja Isakovic
 
Zakaj v startup svetu nikoli ni vrste pred ženskim straniščem?
Zakaj v startup svetu nikoli ni vrste pred ženskim straniščem?Zakaj v startup svetu nikoli ni vrste pred ženskim straniščem?
Zakaj v startup svetu nikoli ni vrste pred ženskim straniščem?Alja Isakovic
 
What about the other half of your customers?
What about the other half of your customers?What about the other half of your customers?
What about the other half of your customers?Alja Isakovic
 
Android for girls: a new frontier
Android for girls: a new frontierAndroid for girls: a new frontier
Android for girls: a new frontierAlja Isakovic
 
Cultures in virtual worlds
Cultures in virtual worldsCultures in virtual worlds
Cultures in virtual worldsAlja Isakovic
 
Online Tutoring Across Different Platforms
Online Tutoring Across Different PlatformsOnline Tutoring Across Different Platforms
Online Tutoring Across Different PlatformsAlja Isakovic
 
Virtualni svet Second Life
Virtualni svet Second LifeVirtualni svet Second Life
Virtualni svet Second LifeAlja Isakovic
 
Virtual Worlds Introduction: Second Life and Beyond
Virtual Worlds Introduction: Second Life and BeyondVirtual Worlds Introduction: Second Life and Beyond
Virtual Worlds Introduction: Second Life and BeyondAlja Isakovic
 
Sloodle Presentation
Sloodle PresentationSloodle Presentation
Sloodle PresentationAlja Isakovic
 

Mehr von Alja Isakovic (19)

Starting a business as engineers: algorithms aren't everything
Starting a business as engineers: algorithms aren't everythingStarting a business as engineers: algorithms aren't everything
Starting a business as engineers: algorithms aren't everything
 
Zakaj moraš med razvojem produkta razmišljati kot obsedeni bivši?
Zakaj moraš med razvojem produkta razmišljati kot obsedeni bivši?Zakaj moraš med razvojem produkta razmišljati kot obsedeni bivši?
Zakaj moraš med razvojem produkta razmišljati kot obsedeni bivši?
 
IoT Design Manifesto: smernice za bolj odgovoren razvoj IoT izdelkov in storitev
IoT Design Manifesto: smernice za bolj odgovoren razvoj IoT izdelkov in storitevIoT Design Manifesto: smernice za bolj odgovoren razvoj IoT izdelkov in storitev
IoT Design Manifesto: smernice za bolj odgovoren razvoj IoT izdelkov in storitev
 
Kako slike mačk pridejo na tvoj računalnik? Kratek, enostaven in mačje obarva...
Kako slike mačk pridejo na tvoj računalnik? Kratek, enostaven in mačje obarva...Kako slike mačk pridejo na tvoj računalnik? Kratek, enostaven in mačje obarva...
Kako slike mačk pridejo na tvoj računalnik? Kratek, enostaven in mačje obarva...
 
Quantified Self: The what, the why and the brave new future
Quantified Self: The what, the why and the brave new futureQuantified Self: The what, the why and the brave new future
Quantified Self: The what, the why and the brave new future
 
def hire_more_women_in_tech(you):
def hire_more_women_in_tech(you):def hire_more_women_in_tech(you):
def hire_more_women_in_tech(you):
 
Git your Jekyll on - WebCamp Ljubljana 2015
Git your Jekyll on - WebCamp Ljubljana 2015Git your Jekyll on - WebCamp Ljubljana 2015
Git your Jekyll on - WebCamp Ljubljana 2015
 
Uvod v internet in programiranje: Enostavno, kratko in prijazno
Uvod v internet in programiranje: Enostavno, kratko in prijaznoUvod v internet in programiranje: Enostavno, kratko in prijazno
Uvod v internet in programiranje: Enostavno, kratko in prijazno
 
Zakaj v startup svetu nikoli ni vrste pred ženskim straniščem?
Zakaj v startup svetu nikoli ni vrste pred ženskim straniščem?Zakaj v startup svetu nikoli ni vrste pred ženskim straniščem?
Zakaj v startup svetu nikoli ni vrste pred ženskim straniščem?
 
What about the other half of your customers?
What about the other half of your customers?What about the other half of your customers?
What about the other half of your customers?
 
Android for girls: a new frontier
Android for girls: a new frontierAndroid for girls: a new frontier
Android for girls: a new frontier
 
Cultures in virtual worlds
Cultures in virtual worldsCultures in virtual worlds
Cultures in virtual worlds
 
Online Tutoring Across Different Platforms
Online Tutoring Across Different PlatformsOnline Tutoring Across Different Platforms
Online Tutoring Across Different Platforms
 
Moodle predstavitev
Moodle predstavitevMoodle predstavitev
Moodle predstavitev
 
Virtualni svet Second Life
Virtualni svet Second LifeVirtualni svet Second Life
Virtualni svet Second Life
 
Sloodle
SloodleSloodle
Sloodle
 
Virtual Worlds Introduction: Second Life and Beyond
Virtual Worlds Introduction: Second Life and BeyondVirtual Worlds Introduction: Second Life and Beyond
Virtual Worlds Introduction: Second Life and Beyond
 
Moodle presentation
Moodle presentationMoodle presentation
Moodle presentation
 
Sloodle Presentation
Sloodle PresentationSloodle Presentation
Sloodle Presentation
 

Kürzlich hochgeladen

Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingEdi Saputra
 
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Bhuvaneswari Subramani
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...Zilliz
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyKhushali Kathiriya
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...DianaGray10
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherRemote DBA Services
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native ApplicationsWSO2
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Orbitshub
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...apidays
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Victor Rentea
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdfSandro Moreira
 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Angeliki Cooney
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...apidays
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024The Digital Insurer
 
Exploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusExploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusZilliz
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamUiPathCommunity
 
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot ModelMcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot ModelDeepika Singh
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...apidays
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWERMadyBayot
 

Kürzlich hochgeladen (20)

Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
Exploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusExploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with Milvus
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
 
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot ModelMcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 

The web and programming: an introduction - Simple, short and friendly

  • 1. The web and programming: an introduction Simple, short and friendly
  • 2. 3 basic question What are web apps and how do they work? What is Ruby, how is it connected to Rails? What is Rails and what can we use it for?
  • 3. How does the web work? • Let’s take a look at an example: - What happens when I type railsgirls.com into my web browser?
  • 4. (109.74.202.152) 1) The web browser looks up the IP address of the web site using DNS I want to know more about Wait, I need to find Rails Girls the address of the web server with that info. Avtor fotografije: Ed Yourdon
  • 5. 2) The broswers sends a “GET” request to the server Hey, I need info Just a moment about Rails Girls ... HTTP request GET Host: railsgirls.com j your computer j host server for railsgirls.com
  • 6. 3) The servers respons with a web page, written in HTML language Aha! Found it! response in HTML language j Let me see what tvoj računalnik j this looks like... host server for railsgirls.com
  • 7. 4) The web browser makes sure the web site is displayed correctly Ta-da! Isn’t this a nice web site?
  • 8. So, what are we going to work on today? j A web app for collecting ideas
  • 9. What will the app look like in our browser?
  • 10. Hmm... what are web apps? And what are web pages?
  • 11. simplesushi.com I want sushi! j j web page Octocat sushi.html Photo by: melanie_hughes
  • 12. sushi.html is as it is! simplesushi.com But ... I don’t eat fish ... j j static sushi.html web page Octocat
  • 13. What about fancysushi.com here? Can I get a sushi without fish? j Octocat
  • 14. web app on the server What about j fancysushi.com here? Can I get a sushi without fish? j Sure, Octocat, our sushi chef Octocat can adjust! Photo by: iwillbehomesoon
  • 15. web app on the server j fancysushi.com j Here’s your Octocat j personalized sushi. sushi.html Would you like a different one? the result is another web page
  • 16. web app on the server j fancysushi.com j Octocat j sushi.html however it is now a dynamic web page, tailored to the user
  • 17. web app In the real world ... on the server j facebook.com j Octocat j that’s why Facebook has different content for each of us
  • 18. If we want to build web apps ...
  • 19. If we want to build web apps ... j We need to be able to talk to the sushi chef on the server
  • 20. Ruby is one of the programming languages that we can use in web apps If you want me to do something, you’ve got to speak Ruby! Other popular languages: PHP, Python, Java, ASP.NET, Perl ...
  • 21. How we can use Ruby to talk to a computer? As a starting point: 1) We need to have Ruby installed (Installation Party!) 2) Use Terminal or Command Prompt (Windows)
  • 22. Simple example Let’s use irb = Interactive RuBy “Rails Girls”
  • 23. irb examples "Rails Girls" # strings 2+2 # integers 2*2 # Ruby as a simple calculator "Rails " * 2 # multiplying a string "Rails " + "Girls" # combining two string "Rails" * "Girls" # multiplying strings doesn’t work "Rails Girls".length # but string do have their own useful methods "Rails Girls".reverse ime = "Rails Girls" # to simplify work, we can store objects into variables ime.length # same method as before used on a variable, same result ime.reverse ime.upcase ime.downcase ime + ime # variables can also be combined, just like before
  • 24. Simple example Let’s save a program into a .rb file for easy access Sublime Text 2 Terminal
  • 28. Even the big, scary dragon is made out of simple Lego blocks! Photo by: themickeyd
  • 29. Bonus tip: learn programming at home with: http://tryruby.org http://www.codeschool.com http://www.codecademy.com
  • 30. What about Rails? Rails = Ruby on Rails = RoR = a framework, which makes sure we can easily use Ruby to build web apps = fast rails for Ruby on the web
  • 31. We’ll build today’s app with Rails ...
  • 32. ... the app will be made with different text files with Ruby, HTML and other code
  • 33. Rails* apps have three basic building blocks MVC architecture = Model | View | Controller Controller = sushi chef accepts requests, makes all parts work as a whole Model = ingredients represents database data View = sushi the representation of the result, * And a lot of other web apps in different languages seen by users Photo by: Michael Kappel
  • 34. Confused? No worries :) When programming: • Googling is a must; • copy-paste a valid method; • getting a working result is what really matters. P.S.: Practice makes perfect!
  • 35. Let’s warm up before we make our own app: getting to know web technologies! My Bentobox Application: Designed by: Storage Logic Backend. Backend. How the application stores data. How the application works. Style and structure Frontend. How the application looks. Infrastructure Backend. How the application runs.