Jason's Stage 4 Notes

Lesson 1: Understanding Networks

Networks

A group of entities that can communicate even though they are not directly connected. There has to be at least three entities and there has to be a way that entities that are not directly connected can still communicate.

This Video does a good job of explaining it.

Servers

A server is a computer that interacts with a request we make to the computer. For example, whenever we type in "http://www.google.com", we are sending a request to Google's servers to return a website.

Get vs Post

Get parameters are included in the URL. Get requests are used for fetching documents. Get parameters have a max URL length. Get parameters are generally ok to cache. Get parameters should not change the server

Post parameters are included in the body. Post parameters are used for updating data or actually making changes. Post parameters have no max length. Post parameters are almost never cached. Post requests are usually destructive in nature.

Server Responses

When you send commands to the server the server will respond with different codes. There are 3 main server response types. 2xx codes indicate Success. 3xx codes indicate a Redirection. or action needs to be taken by the client in order to fulfill the request. 4xx and 5xx codes indicate Error The 4xx codes are intended for cases in which the client seems to have erred, and the 5xx codes for the cases in which the server is aware that the server has erred.

This websiteprovides a great explanation.

Lesson 2: Importance Of Validating Input

Checking Validation

Validation is verifying on the server that what we receive is what we expect to receive. If what we receive is different than what we expect we send a message notifying the user.

It is important that we validate the data and send the appropriate response so that the user knows what the problem is and potentially how to fix it going forward. This Video goes into more detail about this topic.

Handling Bad Data

We need to verify what the user enters and confirm if the data is bad. Using something like a drop-down is not enough to ensure that the user is not passing bad data to our form. It is important that we send appropriate responses or messages if the data is bad or incorrect.

This lesson covers this topic in detail.

Lesson 3: HTML Templates

Introducing Templates

Templates refer to a library used to build complicated strings (html). Jinja2 is a template library that was used to make this web page. Avoiding repetition is necessary when programming. You want to avoid having to rewrite the same code multiple times.

Variable Substitution

The syntax for substituting a variable in Jinja is a double curly brace. Substitution is basically just printing the variable. This is a handy way to substitute a string while maintaining cleaner code.

Template Inheritance

This is a great way to avoid repetition and makes your code more organized and easier to read. This lets you define a base template which you can later plug new HTML into. This is useful when, for example, you want to have a consistent header and footer across your app. Remember better organized code is more readable,easier to fix, easier to share, and harder to break.

Lesson 4: JavaScript

What is JavaScript?

JavaScript is the main programming language used with HTML and the Web. JavaScript can be used to create interactive effects within your web page.

This Wikipedia page has a great definition.

Where to use JavaScript?

If you are like me you are probably wondering how you can use JavaScript in your web page. According to this website. JavaScript can be placed in the body and head sections of an HTML page.

JavaScript Syntax

JavaScript syntax is a set of rules for how programs are constructed. JavaScript statements are separated by semicolons. There are two main types of values: Fixed values and variable values. Visit this page for more details about JavaScript syntax.



Login
anonymous@anonymous.com wrote:
Where did you go to university? https://www.drugonsale.com cialis As well as two types of macarons there are delicate chocolates, millefeuilles, ph-stamped waffles, pastries, layer cakes, pound cakes, nougats and éclairs. 'It is great for me to be able to show off a whole range like this,’ Hermé says. So after more than three decades of making pastries, can he still stand to eat his creations? 2018-06-09 22:49:43.866590
anonymous@anonymous.com wrote:
I went to <a href=" https://www.drugonsale.com ">kamagra</a> With the shutdown, sailors have complained about delays inannual payments of re-enlistment bonuses, military academieshave scaled back classes and key Pentagon offices - includingones dealing with intelligence matters - have been hollowed out.Even U.S. commissaries selling groceries to military familieshave been shuttered. 2018-06-09 22:15:45.335980
anonymous@anonymous.com wrote:
How many days will it take for the cheque to clear? https://www.drugonsale.com purchase medication online On the other hand, Lockhart said, "If we see a deterioration from this point, and I would say my more realistic fear is just a kind of ambiguous picture of mixed data that signal neither accelerating strength nor necessarily deterioration, but that kind of moping along in the middle, then I think it's not a foregone conclusion that the asset purchase program should be removed or be removed rapidly." 2018-06-09 20:08:41.203640
anonymous@anonymous.com wrote:
Stolen credit card https://www.drugonsale.com viagra WARSAW, Oct 8 (Reuters) - Poland's state railway operator isset to raise up to $518 million by selling shares in PKP Cargo,the European Union's second-biggest freight company, in what isexpected to be Warsaw's largest stock market debut this year. 2018-06-09 19:50:50.619670
anonymous@anonymous.com wrote:
I've just started at <a href=" https://www.drugonsale.com ">purchase medication online </a> As House Republicans worry more about a challenge to their right flank than defeat from a Democratic challenger back home, they push their party farther from the mainstream even as their own seats remain secure. 2018-06-09 19:35:00.865710
anonymous@anonymous.com wrote:
Other amount https://www.drugonsale.com kamagra Forecasters at the Colorado State University slightlylowered their forecast for the season, predicting eighthurricanes, with three developing into major hurricanes ofCategory 3 or higher on the five-step Saffir-Simpson intensityscale. 2018-06-09 19:32:14.134800
anonymous@anonymous.com wrote:
I'm interested in this position <a href=" https://www.drugonsale.com ">purchase medication online </a> Your email associated with your SUN account has not been validated. If you have received your validation email, please click the link provided to validate now. To receive a new validation email go to your SUN account and follow the instructions. 2018-06-09 19:16:44.111680
anonymous@anonymous.com wrote:
There's a three month trial period <a href=" https://www.drugonsale.com#pack ">cheap order drugs</a> "It was a positive thing, you know? It wasn't a groundball that went through my legs or a strikeout. It was something that I did good," said Brett, who played his entire Hall of Fame career with the Royals and is now serving as their interim hitting coach. 2018-06-09 18:58:15.166970
anonymous@anonymous.com wrote:
I've only just arrived https://www.drugonsale.com kamagra JPM say in a note today that assets benchmarked to the CEMBI have crossed $50.6 billion, having risen 60 percent year-over-year.  Interest in corporates is strong also among investors who don&#8217;t usually focus on this sector, the bank says, citing the results of its monthly client survey. One such example is asset manager Schroders. Skeptical a couple of years ago about the risk-reward trade-off in emerging debt, Schroders said last month it was seeing more opportunities in emerging corporates, noting: 2018-06-09 17:40:11.819750
anonymous@anonymous.com wrote:
I'm afraid that number's ex-directory <a href=" https://www.drugonsale.com#supplied ">cheap order drugs</a> One week Smith treats the ball like a hand grenade and keeps handing it to the other team. The next week he treats it like a stack of gold and only lets his teammates touch it. And Sunday, when the Jets were down 16-6 halfway through the third quarter, he once again failed to take care of the football. 2018-06-09 16:57:14.653020