Creating Basic Form
Let's take a look at Add.cshtml.
- The form uses "post" method to send the form values.
- There are class tags that relate to CSS boostrap syntax.
- "col-md-6" means it will use 6 out of 12 parts of the page to display the content.
- Notice "for" element in HTML tag. It is used to tell the browser that this label is for the input element whose ID is date.
- Notice "name" element in HTML tag. It is used to reference elements after the form is being submitted.
- Try to run Add.cshtml and fill the Date input as 1/1/2016.
- Check the Network tab in inspect element to get a brief look at how the form is being submitted.
- Take a quick look at difference of GET and POST method here: https://www.w3schools.com/tags/ref_httpmethods.asp