The final part I will cover on HTML is Lists and Forms. As it says on the tin, lists are used to create lists. There are two types of list, un-ordered and ordered. An un-ordered list is used for when it does not matter what order your items are listed in. The ordered list will list your items in ordered numbers.
To create these lists, you will use the <ul> or <ol> tags. Within these tags, you will use the <li> tag to create a List Item. See example below:
Forms are used to give the user a chance to enter some sort of input into your website. This will useful later when we are doing JS as it will enable us to process the users data, but for the meantime we'll just learn how to create forms.
To create a form, you will use the <form> tag. Within these form tags, you will use the <input> tag to create an Input Type. This input type can be anything from a text box to radio buttons. When creating an input, you must state what sort of input it is by using an attribute. e.g. type="text"
See the code and output below for clarification:
No comments:
Post a Comment