Note 02 HTML PDF
Note 02 HTML PDF
HTML Background
November 1990, first created by Tim Berners Lee, the father/inventor of WWW Knighted by Queen Victoria in 2004 Hypertext is text which is not constrained to be linear. HyperMedia is a term used for hypertext which is not constrained to be text: it can include graphics, video and sound , for example
Words To Know
Tag - Used to specify ("mark-up") regions of HTML documents for the web browser to interpret. Tags look like this: <tag> Element - A complete tag, having an opening <tag> and a closing </tag>. Attribute - Used to modify the value of the HTML element. Elements will often have multiple attributes.
Simple Meaning
For now just know that:
a tag is a command the web browser interprets, an element is a complete tag, and an attribute customizes or modifies HTML elements.
WYSIWYG
Dreamweaver let you create pages quickly but you can only spicing up or polishing up HTML effects manually cant do that if doesnt know HTML
HTML attributes
Attributes are properties of tags. For example
<font face=Arial color=#FF0000 size=+3> The tag is <font> and the properties are:
Face Color Size
Image
<img src=image file name . . . > Activity 04
<img src="sunset.gif" width="96" height="63" alt="This is an image of sunset" />
Activity 05
Image (cont.)
Alternative Attribute
The alt attribute specifies alternate text to be displayed if for some reason the browser cannot find the image, or if a user has image files disabled. Text only browsers also depend on the alt attribute since they cannot display pictures. Activity 06
Link
<a href=reference object . . . >linked object</a> reference object :
Part of text in the same document Other document Image / animation / audio / video Application logic (CGI script) Client script (JavaScript / VBScript)
linked object :
Text Image
Outside document
Same website only dir. Without full url/http
<a href="http://www.utm.my">Link-(UTM homepage)</a> Image link <a href="http://www.utm.my"><img src="utm-scale.gif" width="230" height="230" border="0" /></a>
Table
Begin table Begin row Column1, Column2, . . . End row ... End table
Table
Begin table = <table . . . > End table = </table> Begin row = <tr . . . > End row = </tr> Column = <td . . . > column content </td> column content : text, image, linked object, etc.
Cell pading: distance between cell borders and content: <table cellpadding="10> Cell spacing: width of cell border:
<table cellspacing="10>
Table
Table with 2 rows & 3 columns for each row: <table border cols=3 rows=2 width=100%> <tr><td>1</td><td>2</td><td>3</td></tr> <tr><td>4</td><td>5</td><td>6</td></tr> </table>
There are two rows: <table> <tr> . . .</tr> <tr> . . .</tr> </table>
First row -> two columns Second row -> one column <table> <tr> <td>. . .</td> <td> . . . </td> </tr> <tr> <td> . . . </td></tr> </table>
Span two columns for the single column in the second row: <table> <tr> <td>. . .</td> <td> . . . </td> </tr> <tr> <td colspan=2> . . . </td></tr> </table> Activiti 11
There are two rows (max): <table> <tr> . . .</tr> <tr> . . .</tr> </table>
is the first column in the first row is the second column in the first row is the second column in the second row
<table> <tr> <td>. . .</td> <td>. . .</td> </tr> <tr> <td>. . .</td> </tr> </table> Activity 12
<table> <tr> <td rowspan=2>. . .</td> <td>. . .</td> </tr> <tr> <td>. . .</td> </tr> </table>
Form
Begin form Form object components End form
Form
Begin form = <form . . . > Form object components = Textfiled, Password, Hidden, TextArea, List Box (single/multiple), Radio Button, Check Box, Submit Button, Reset Button, Buttons End form = </form>
Form Activity 14
<form method=? action=? > Form object components </form>
Check Box
<input type=checkbox name=c1 value=v1>Text 1 <input type=checkbox name=c2 value=v2 checked>Text 2 <input type=checkbox name=c3 value=v3>Text 3 ...
Frame Object
display multiple HTML documents simultaneously in the same browser window Why use frame ? provide permanent navigation menu
Frame Object
General Implementation Begin set of frame frame1 frame2 End set of frame
Frame Object
Begin set of frame: <frameset rows / cols =?, ?"> Frame: <frame src=?" name=?"> End set of frame: </frameset>
Frame Object
Nested frame <frameset rows = 20%, *> <frame src=? name=top> <frameset cols = 25%, *> <frame src=? name=bottom_left> <frame src=? name=bottom_right> </frameset> </frameset>