Monday, 19 May 2014

HTML

HTML was the first way that you could create a website. HTML was the way that everybody would create a website now there are various programs that will do all the hard work for you. Such as Adobe Dreamweaver.
In the image about you will see the first step of the process of creating a website using HTML. In the first step we opened a black notepad document and wrote in “This is my first page”. Then we save ha to save the file as an .hmtl so that the Pc would know that that document was a HMTL code and would work with an internet browser. Then I saved the document and started to create a webpage using HMTL. Also HMTL stands for Hyper Text mark-up language.
In this image I have added a tag. There are 3 different tags in this image: <!DOCTYPE html>, <html>, <body>. The first tag, <!DOCTYPE html>, is there to let that web browser know what you are what type of html you are using. If you do not add this in then the code that you type in will not present you with the outcome that you desire. The next tag, <html> tell the web browser that all the content between the opening and closing tag of <html> and </html> is all an html document. The final tag <body> is there to tell the web browser that everything between the <body> and </body> are the main body of text that will be on the webpage.
I this step I added a title. The title of the web page it the tab of the page and the title is also used if you bookmark and favourite the webpage. With <head><title>my first web page</title></head>.
In the fourth step I added a paragraph. The in the content of the document if you were to just press enter and go to a new line then you think that it would do the same in the web page, but it doesn't. To create a new paragraph you have to start the new paragraph with <p> and end it with </p> then the content in between will be put onto a new line on the web page.
In this image I am adding a heading. The html code for the headings is <h1></h1>. The number after the h is relative to the size and order of the heading.
In this image I am adding lists to the document. The way to do this is to add the codes <ul>, <li> and <ol>. <ul> defines that you want to start a list. <li>, this code tells the web browser that is this the list. Finally <ol>, this code tells the web browser that you want to add in a sub list within the list that you have created.
I added a link to the web page by adding the hmtl code <a href="http://www.htmlgog.com">HTML Dog</a>. The <a> tell the web browser that the following content is going to be a link. The “href” part to the code is telling the web browser the destination of the link. The “HTML Dog” part of the code is where about on the website the link is.
In the image above I’ve added an image to the web page. I did this by add the html code <img src="http://www.htmldog.com/badge1.gif" width="120" height"90" alt="HTML Dog">
</body>. “src=” this part is the location to the image that you wish to put onto the website. “width= and height=” these are self-explanatory in they allow you to change the size of the image. The “alt=” is the part of the code that is there for people that can’t see the image and need and audio description of it or people that can see the image properly and need a description of the image.
In this image I have added a table to the web page the three codes you need for this are <table>, this inform the web browser that everything in between the open and close code is a table. The next code you need is <tr> this is what you need for the table row. Finally you need <td> is the data cell.
This final image shows you how to create a form using html. Firstly there is a drop down options menu. You create this by using the html code <select> on the outside. The next code you will need it <option> this code allows you to create the option that you wish to put inside of your drop down menu. Next, there is a single line input box for names the code to allow you to do this is <input name="name" value="Your name">. The next code is to create a large text box the code for this is <textarea rows="10" cols="20" name="comments">Your comments</textarea>. The <textarea> is telling the browser was it is and the rest of the code in the middle is the information about it. Second to last there is an options menu. The code is <input type="radio" name="areyou" value="male"> this code will allow you to create the option for a male. This type of options menu is not clumped together in the code like the drop down menu is but instead they are all individual. And finally there is a submit button that allows the reader of the webpage you submit the form, the code for this is <input type="submit">.






No comments:

Post a Comment