reading-notes

Todd Wolden

View on GitHub

Course 201 Class 1 “Foundations of Software Development”

Clients and servers

Clients: are the typical web user’s internet-connected devices (for example, your computer connected to your Wi-Fi, or your phone connected to your mobile network) and web-accessing software available on those devices (usually a web browser like Firefox or Chrome).

Servers: are computers that store webpages, sites, or apps. When a client device wants to access a webpage, a copy of the webpage is downloaded from the server onto the client machine to be displayed in the user’s web browser.

In addition to the client and the server we have:

Explanation of what happens when you type a web address into your browser

  1. The browser goes to the DNS server, and finds the real(numerical) address of the server that the website lives on.
  2. The browser sends an HTTP request message to the server, asking it to send a copy of the website to the client. This message, and all other data sent between the client and the server, is sent across your internet connection using TCP/IP.
  3. If the server approves the client’s request, the server sends the client a “200 OK” message and then starts sending the website’s files to the browser as a series of small chunks called data packets.
  4. The browser assembles the small chunks into a complete web page and displays it to you.

Order in which component files are parsed

JavaScript Basics

A powerful programming language that can add interactivity to a website.

Variables: are containers that store values. You start by declaring a variable with the let keyword, followed by the name you give to the variable.

JavaScript is case sensitive. When you have issues remember this and check your variable names.

Comments: are snippets of text that can be added along with code. The browser ignores text marked as comments. You can write comments in JavaScript just as you can in CSS. use /* */ to open and close comments or // and everything behind it is a comment.

Operators: Mathmatecial symbols that produce a result based on tw or more inputs.(numerical or variables)

Functions: Are a way of repackaging code you want to resue or recall later. The use of functions saves time and helps keep the code clean.

Intro to HTML

HTML(HyperText Markup Language) is a markup language that tells web browsers how to structure the web page you are viewing.

The HTML Element is made up an opening tag, attributes, content, and a closing tag.

JavaScript running order: When the browser encounters a block of JavaScript, it generally runs it in order, from top to bottom. This means that you need to be careful what order you put things in.

Dynamic versus static code: The ability to update the display of a web page/app to show different things in different circumstances, generating new content as required whereas Static code shows the same content all the time.

Interpreted versus compiled code: In interpreted languages you don’t have to transform the code into a different form before it is ran, but in compiled languages are transformed or “compiled” into another form before that code is ran by the computer.

Things I want to know more about

Questions Related to “How the Web Works” Reading:

1. Compose a short poem describing how HTTP sends data between computers.

 The browser you are using contacts the DNS and finds the website's numerical address. Then the browser uses HTTP request to contact the server asking it to send a copy of the website back to the client side. If the server approves the request it send small chunk of data called packets back to the client. The client's browser reorders the packets into the correct sequence and displays the web page.(I am not sure this actually qualifies as a poem)

2. Describe how HTML, CSS, and JS files are “parsed” in the browser.
 
 The HTML is parsed first. This allows for links to CSS and JavaScript files to be recognized. The browser uses data from those files to build a Document Object Model(DOM) tree and a CSS Object Model(CSSOM) structure from the parsed CSS files. It also compiles and executes the parsed JavaScript. The browser as it builds the DOM file is also executing the CSS styling and executing the Javascript which builds the inteactive web page.

3. How can you find images to add to a Website?

 You can use Google to find Creative Commons licenses or public domain photos to use. You could also use personal images you took and own the copyright to if they are appropriate to the project. 

4. How do you create a String vs a Number in JavaScript?
 
 You enclose the string with single quotation marks where as a number does not have quotations around it.

5. What is a Variable and why are they important in JavaScript?
 
 A variable is a container that stores values. They are imprortant because they allow you to assign a name to any vale you desire and recall it later in the code. This can save time and keep your code clean.

Questions related to HTML reading:

1. What is an HTML attribute?

 An HTML attribute is a part of the element that contains extra information about the elemnet that will not show up in the content.

2. Describe the Anatomy of an HTMl element.

 The element starts with an opening tag followed by the attribute within the opening tag if the element has an attribute. After the opening tag is the content followed by the closing tag.

3. What is the Difference between <article> and <section> element tags?

 The <article> element tag is a more specific kind of <section> tag that refers to a specific self-contained or independent block of related content.

4. What Elements does a “typical” website include?

 It would include a head which contains metadata about the document. It would also include a body section. The body would have the header, all the content a viewer sees, and the footer included in it.

5. How does metadata influence Search Engine Optimization?

 The type and amount of data you include could greatly influence serch engine results. Without a correct name and description you could be left out of relevant searches. Well defined metadata could increase you hits in searches. Adding things like author's name could drive traffic toward your site.

6. How is the <meta> HTML tag used when specifying metadata?

 It is used as a self-closing tag style.

Miscellaneous Questions:

Return to the Table of Contents: Table of Contents