إعـــــــلان

تقليص
لا يوجد إعلان حتى الآن.

ááí íÍÈ íÊÚáã Çá html

تقليص
هذا الموضوع مغلق.
X
X
 
  • تصفية - فلترة
  • الوقت
  • عرض
إلغاء تحديد الكل
مشاركات جديدة

  • ááí íÍÈ íÊÚáã Çá html

    Çæá ÔíÁ íÝÊÎ ÇáäæÊ ÈÇÏ (notepad)

    æíÍÝÖ Úáì ÇáÅÓã ÇáÐí íÑíÏå Ëã htm.

    æ íßãá ÇáÊÍÊí

    [align=left]HTML

    1-HTML and WWW:
    What is the World Wide Web?
    The World Wide Web (WWW) is most often called the Web.
    The Web is a network of computers all over the world.
    All the computers in the Web can communicate with each other.
    All the computers use a communication standard called HTTP.
    How does the WWW work?
    Web information is stored in documents called Web pages.
    Web pages are files stored on computers called Web servers.
     Computers reading the Web pages are called Web clients.
    Web clients view the pages with a program called a Web browser.
    Popular browsers are Internet Explorer and Netscape Navigator.
    How does the browser fetch the pages?
    A browser fetches a Web page from a server by a request.
    A request is a standard HTTP request containing a page address.
    A page address looks like this: http://www.someone.com/page.htm.
    How does the browser display the pages?
    All Web pages contain instructions for display
    The browser displays the page by reading these instructions.
    The most common display instructions are called HTML tags.
    HTML tags look like this <p>This is a Paragraph</p>.
    Who is making the Web standards?
    The Web standards are not made up by Netscape or Microsoft.
    The rule-making body of the Web is the W3C.
    W3C stands for the World Wide Web Consortium.
    W3C puts together specifications for Web standards.
    The most essential Web standards are HTML, CSS and XML.
    The latest HTML standard is XHTML 1.0.
    2-Introduction to HTML
    What is an HTML File?
    • HTML stands for Hyper Text Markup Language
    • An HTML file is a text file containing small markup tags
    • The markup tags tell the Web browser how to display the page
    • An HTML file must have an htm or html file extension
    • An HTML file can be created using a simple text editor
    A Simple Example
    <html>
    <head>
    <title>Title of page</title>
    </head>
    <body>
    This is my first homepage. <b>This text is bold</b>
    </body>
    </html>
    HTM or HTML Extension?
    When you save an HTML file, you can use either the .htm or the .html extension. We have used .htm in our examples. It might be a bad habit inherited from the past when some of the commonly used software only allowed three letter extensions.
    With newer software we think it will be perfectly safe to use .html.
    • Note on HTML Editors:
    You can easily edit HTML files using a WYSIWYG (what you see is what you get) editor like FrontPage, Claris Home Page, or Adobe PageMill instead of writing your markup tags in a plain text file.

    3-HTML Elements
    HTML documents are text files made up of HTML elements.
    HTML elements are defined using HTML tags.
    HTML Tags
    • HTML tags are used to mark-up HTML elements
    • HTML tags are surrounded by the two characters < and >
    • The surrounding characters are called angle brackets
    • HTML tags normally come in pairs like <b> and </b>
    • The first tag in a pair is the start tag, the second tag is the end tag
    • The text between the start and end tags is the element content
    • HTML tags are not case sensitive, <b> means the same as <B>
    HTML Elements
    <html>
    <head>
    <title>Title of page</title>
    </head>
    <body>
    This is my first homepage. <b>This text is bold</b>
    </body>
    </html>
    Tag Attributes
    • Tags can have attributes
    • Attributes can provide additional information about the HTML elements
    • <body> tag defines the body element of your HTML page with an
    added bgcolor attribute, background color of page can be red
    <body bgcolor="red”>.
    • <table> tag defines an HTML table with an added border attribute.
    Table with no borders <table border="0”>
    Attributes always come in name/value pairs like this: name="value".
    Attributes are always added to the start tag of an HTML element.
    Quote Styles, "red" or 'red'?
    Attribute values should always be enclosed in quotes. Double style quotes are the most common, but single style quotes are also allowed.
    In some rare situations, like when the attribute value itself contains quotes, it is necessary to use single quotes: name='John "ShotGun" Nelson'
    4-Basic HTML Tags
    The most important tags in HTML are tags that define headings, paragraphs and line breaks.
    Headings
    Headings are defined with the <h1> to <h6> tags. <h1> defines the largest heading. <h6> defines the smallest heading.
    <h1>This is a heading</h1>
    <h2>This is a heading</h2>
    <h3>This is a heading</h3>
    <h4>This is a heading</h4>
    <h5>This is a heading</h5>
    <h6>This is a heading</h6>
    HTML automatically adds an extra blank line before and after a heading.
    Paragraphs
    Paragraphs are defined with the <p> tag.
    <p>This is a paragraph</p>
    <p>This is another paragraph</p>
    HTML automatically adds an extra blank line before and after a paragraph.
    Line Breaks
    The <br> tag is used when you want to end a line, but don't want to start a new paragraph. The <br> tag forces a line break wherever you place it.
    <p>This <br> is a para<br>graph with line breaks</p>
    The <br> tag is an empty tag. It has no closing tag.
    Comments in HTML
    The comment tag is used to insert a comment in the HTML source code. A comment will be ignored by the browser. You can use comments to explain your code, which can help you when you edit the source code at a later date.
    <!-- This is a comment -->
    Note that you need an exclamation point after the opening bracket, but not before the closing bracket.
    Example:
    >html<
    <body bgcolor="yellow”>
    !-->This comment will not be displayed<--
    <p>This is a regular paragraph</p>
    <p>
    To break<br>
    lines<br>
    in a<br>paragraph,<br>use the br tag.
    >p</
    >hr<
    <p>This is a paragraph</p>
    <hr>
    <body/>
    <html/>
    5-HTML Text Formatting HTML defines a lot of elements for formatting output, like bold or italic text.
    This example demonstrates how you can format text in an HTML document -
    <html>
    <body>
    <b>This text is bold</b>
    <br>
    <strong>This text is strong<strong>
    <br>
    <big>This text is big>big</
    <br>
    >em<This text is emphasized>em</
    <br>
    >i<This text is italic>i</
    <br>
    >small<This text is small>small</
    <br>
    This text contains
    >sub<subscript>sub</
    <br>
    This text contains
    >sup<superscript>sup</
    >body</
    >html</
    Preformatted text
    This example demonstrates how you can control the line breaks and spaces with the pre tag.
    <html>
    <body>
    >pre<
    This is
    preformatted text.
    It preserves both spaces
    and line breaks.
    >pre</
    <p>The pre tag is good for
    displaying computer code:</p>
    >pre<
    for i = 1 to 10
    print i
    next i
    >pre</
    >body</
    >html</
    "Computer output" tags
    This example demonstrates how different "computer output" tags will be displayed.
    <html>
    <body>
    <code>Computer code</code>
    <br>
    <kbd>Keyboard input</kbd>
    <br>
    <tt>Teletype text</tt>
    <br>
    <samp>Sample text</samp>
    <br>
    <var>Computer variable</var>
    <br>
    <p>
    <b>Note:</b> These tags are often
    used to display computer/programming
    code.
    >p<
    >body</
    <html</

    Abbreviations and acronyms
    This example demonstrates how to handle an abbreviation or an acronym.
    <html>
    <body>
    <abbr title="United Nations”>UN</abbr>
    <br>
    <acronym title="World Wide Web”>WWW</acronym>
    <p>The title attribute is used to
    show the spelled-out version when
    holding the mouse pointer over the
    acronym or abbreviation.</p>
    <p>This only works for the acronym
    element in IE 5.</p>
    <p>This works for both the abbr and
    acronym element in Netscape 6.2.</p>
    >body</
    >html</
    Text direction
    This example demonstrates how to change the text direction.
    <html>
    <body>
    <p>
    If your browser supports bi-directional
    override (bdo), the next line will be
    written from the right to the left (rtl):
    >p</
    >bdo dir="rtl”>
    Here is some Hebrew text
    >bdo</
    >body</
    >html</
    Quotations
    This example demonstrates how to handle long and short quotations.
    <html>
    <body>
    Here comes a long quotation:
    >blockquote<
    This is a long quotation. This is
    a long quotation.
    This is a long quotation.
    This is a long quotation.
    This is a long quotation.
    >blockquote</
    Here comes a short quotation:
    >q<
    This is a short quotation
    >q</
    >p<
    With the block quote element,
    the browser inserts line breaks
    and margins, but the q element does
    not render as anything special.
    >p</
    >body</
    >html</

    Deleted and inserted text
    This example demonstrates how to mark a text that is deleted or inserted to a document.
    <html>
    <body>
    >p<a dozen is
    <del>twenty</del>
    <ins>twelve</ins>
    pieces
    >p</
    >p<
    Most browsers will overstrike deleted
    text and underline inserted text.
    >p</
    >p<
    Some older browsers will display deleted
    or inserted text as plain text.
    >p</
    >body</
    >html</
    Note : HTML Source : To find out, simply click on the VIEW option in your browsers toolbar and select SOURCE or PAGE SOURCE. This will open a window that shows you the actual HTML of the page..

    Text Formatting Tags
    Tag Description
    <b>
    Defines bold text
    <big>
    Defines big text
    <em>
    Defines emphasized text
    <i>
    Defines italic text
    <small>
    Defines small text
    <strong>
    Defines strong text
    <sub>
    Defines subscripted text
    <sup>
    Defines superscripted text
    <ins>
    Defines inserted text
    <del>
    Defines deleted text
    "Computer Output" Tags
    Tag Description
    <code>
    Defines computer code text
    <kbd>
    Defines keyboard text
    <samp>
    Defines sample computer code
    <tt>
    Defines teletype text
    <var>
    Defines a variable
    <pre>
    Defines preformatted text
    Citations, Quotations, and Definition Tags
    Tag Description
    <abbr>
    Defines an abbreviation
    <acronym>
    Defines an acronym
    <address>
    Defines an address element
    <bdo>
    Defines the text direction
    <blockquote>
    Defines a long quotation
    <q>
    Defines a short quotation
    <cite>
    Defines a citation
    <dfn>
    Defines a definition term
    6-HTML Character Entities
    Some characters like the < character, have a special meaning in HTML, and therefore cannot be used in the text.
    To display a less than sign (<) in HTML, we have to use a character entity.
    Character Entities
    To display such characters, insert character entities in the HTML source.
    A character entity has three parts: an ampersand (&), an entity name or a # and an entity number, and finally a semicolon (.
    To display a less than sign < in an HTML document we must write: < or <
    • Advantage of using a name instead of a number, name is easier to remember.
    • Disadvantage : not all browsers support the newest entity names, while the support for entity numbers is very good in almost all browsers.
    Note: The entities are case sensitive.
    This example lets you experiment with character entities: Character Entities
    Non-breaking Space
    o The most common character entity in HTML is the non-breaking space.
    o To add spaces to your text, use the character entity.
    The Most Common Character Entities:
    Result Description Entity Name Entity Number
    non-breaking space
    < less than < <
    > greater than > >
    & ampersand & &
    " quotation mark " "
    ' apostrophe '
    Some Other Commonly Used Character Entities:
    Result Description Entity Name Entity Number
    ¢ cent ¢ ¢
    £ pound £ £
    ¥ yen ¥ ¥
    § section § §
    © copyright © ©
    ® registered trademark ® ®
    × multiplication × ×
    ÷ division ÷ ÷
    7-HTML Links
    The Anchor Tag and the Href Attribute
    HTML uses the <a> (anchor) tag to create a link to another document.
    An anchor can point to any resource on the Web : an HTML page, an image, a sound file, a movie, etc.
    The syntax of creating an anchor:
    <a href="url”>Text to be displayed</a>
    The <a> tag is used to create an anchor to link from, the href attribute is used to address the document to link to, and the words between the open and close of the anchor tag will be displayed as a hyperlink.
    This anchor defines a link to W3Schools:
    <a href="http://www.w3schools.com/”>Visit W3Schools!</a>
    The line above will look like this in a browser: Visit W3Schools!
    The Target Attribute
    With the target attribute, you can define where the linked document will be opened.
    The line below will open the document in a new browser window:
    <a href="http://www.w3schools.com/";
    target="_blank”>Visit W3Schools!</a>
    The Anchor Tag and the Name Attribute
    o The name attribute is used to create a named anchor.
    o using named anchors we can create links that jump directly into a specific section on a page, instead of letting the user scroll around to find what he is looking for.
    Below is the syntax of a named anchor:
    <a name="label”>Text to be displayed</a>
    o The name attribute is used to create a named anchor.
    o The name of the anchor can be any text you care to use.
    The line below defines a named anchor:
    <a name="tips”>Useful Tips Section</a>
    o You should notice that a named anchor is not displayed in a special way.
    To link directly to the "tips" section, add a # sign and the name of the anchor to the end of a URL, like this:
    <a href="http://www.w3schools.com/html_links.asp#tips”>
    Jump to the Useful Tips Section</a>
    A hyperlink to the Useful Tips Section from WITHIN the file "html_links.asp" will look like this:
    <a href="#tips”>Jump to the Useful Tips Section</a>
    HTML uses a hyperlink to link to another document on the Web.
    Examples : Create hyperlinks
    This example demonstrates how to create links in an HTML document.
    <html>
    <body>
    <p>
    <a href="lastpage.htm”>
    This text</a> is a link to a page on
    this Web site.
    </p>
    <p>
    <a href="http://www.microsoft.com/”>
    This text</a> is a link to a page on
    the World Wide Web.
    </p>
    </body>
    </html>
    An image as a link
    This example demonstrates how to use an image as a link.
    <html>
    <body>
    <p>
    You can also use an image as a link:
    <a href="lastpage.htm”>
    <img border="0" src="buttonnext.gif"
    width="65" height="38”>
    </a>
    </p>
    </body>
    </html>
    (You can find more examples at the bottom of this page)
    More Examples
    Open a link in a new browser window
    This example demonstrates how to link to another page by opening a new window, so that the visitor does not have to leave your Web site.
    <html>
    <body>
    <a href="lastpage.htm"
    target="_blank”>Last Page</a>
    <p>
    If you set the target attribute
    of a link to "_blank",
    the link will open in a new window.
    </p>
    </body>
    </html>
    Link to a location on the same page
    This example demonstrates how to use a link to jump to another part of a document.
    <html>
    <body>
    <p>
    <a href="#C4”>
    See also Chapter 4.
    </a>
    </p>
    <p>
    <h2>Chapter 1</h2>
    <p>This chapter explains 1ba bla bla</p>
    <h2>Chapter 2</h2>
    <p>This chapter explains 2ba bla bla</p>
    <h2>Chapter 3</h2>
    <p>This chapter explains 3ba bla bla</p>
    <a name="C4”><h2>Chapter 4</h2></a>
    <p>This chapter explains 4ba bla bla</p>
    </body>
    </html>
    Break out of a frame
    This example demonstrates how to break out of a frame, if your site is locked in a frame.
    <html>
    <body>
    <p>Locked in a frame?</p>
    <a href="http://www.w3schools.com/";
    target="_top”>Click here!</a>
    </body>
    </html>

    Create a mailto link
    This example demonstrates how to link to a mail message (will only work if you have mail installed).
    <html>
    <body>
    <p>
    This is a mail link:
    <a href="mailto:[email protected]?
    subject=Hello%20again”>
    Send Mail</a>
    </p>
    <p>
    <b>Note:</b> Spaces between words should be
    replaced by %20 to <b>ensure</b> that the
    browser will display your text properly.
    </p>
    </body>
    </html>
    Create a mailto link 2
    This example demonstrates a more complicated mailto link.
    <html>
    <body>
    <p>
    This is another mailto link:
    <a href="mailto:[email protected]?cc=
    [email protected]&bcc=
    [email protected]&subject
    =Summer%20Party&body=You%20are%20invited
    %20to%20a%20big%20summer%20party!”>Send mail!</a>
    </p>
    <p>
    <b>Note:</b> Spaces between words should be
    replaced by %20 to <b>ensure</b> that the browser
    will display your text properly.
    </p>
    </body>
    </html>
    8-HTML Frames
    • With frames, you can display more than one HTML document in the same browser window.
    • Each HTML document is called a frame, and each frame is independent of the others.
    The disadvantages of using frames are:
    • The web developer must keep track of more HTML documents
    • It is difficult to print the entire page________________________________________

    The Frameset Tag
    • The <frameset> tag defines how to divide the window into frames
    • Each frameset defines a set of rows or columns
    • The values of the rows/columns indicate the amount of screen area each row/column will occupy
    ________________________________________
    The Frame Tag
    • The <frame> tag defines what HTML document to put into each frame
    In the example below we have a frameset with two columns.
    The first column is set to 25% of the width of the browser window.
    The second column is set to 75% of the width of the browser window.
    The HTML document "frame_a.htm" is put into the first column, and the HTML document "frame_b.htm" is put into the second column:
    <frameset cols="25%,75%">
    <frame src="frame_a.htm">
    <frame src="frame_b.htm">
    </frameset>
    ________________________________________
    Basic Notes - Useful Tips
    If a frame has visible borders, the user can resize it by dragging the border. To prevent a user from doing this, you can add noresize="noresize" to the <frame> tag.
    Add the <noframes> tag for browsers that do not support frames.
    ________________________________________
    Examples
    Vertical frameset
    This example demonstrates how to make a vertical frameset with three different documents.
    <html>
    <frameset cols="25%,50%,25%”>
    <frame src="tryhtml_frame_a.htm”>
    <frame src="tryhtml_frame_b.htm”>
    <frame src="tryhtml_frame_c.htm”>
    </frameset>
    </Html>
    Horizontal frameset
    This example demonstrates how to make a horizontal frameset with three different documents.
    <html>
    <frameset rows="25%,50%,25%”>
    <frame src="tryhtml_frame_a.htm”>
    <frame src="tryhtml_frame_b.htm”>
    <frame src="tryhtml_frame_c.htm”>
    </frameset>
    </html>
    How to use the <noframes> tag
    This example demonstrates how to use the <noframes> tag.
    <html>
    <frameset cols="25%,50%,25%”>
    <frame src="tryhtml_frame_a.htm”>
    <frame src="tryhtml_frame_b.htm”>
    <frame src="tryhtml_frame_c.htm”>
    <noframes>
    <body>Your browser does not
    handle frames!</body>
    </noframes>
    </frameset>
    </html>
    More Examples
    Mixed frameset
    This example demonstrates how to make a frameset with three documents, and how to mix them in rows and columns.
    <html>
    <frameset rows="50%,50%”>
    <frame src="tryhtml_frame_a.htm”>
    <frameset cols="25%,75%”>
    <frame src="tryhtml_frame_b.htm”>
    <frame src="tryhtml_frame_c.htm”>
    </frameset>
    </frameset>
    </html>
    Frameset with noresize="true"
    This example demonstrates the noresize attribute. The frames are not resizable. Move the mouse over the borders between the frames and notice that you can not move the borders.
    <html>
    <frameset rows="50%,50%”>
    <frame noresize="true" src="tryhtml_frame_a.htm”>
    <frameset cols="25%,75%”>
    <frame noresize="true" src="tryhtml_frame_b.htm”>
    <frame noresize="true" src="tryhtml_frame_c.htm”>
    </frameset>
    </frameset>
    </html>
    Navigation frame
    This example demonstrates how to make a navigation frame. The navigation frame contains a list of links with the second frame as the target. The file called "tryhtml_contents.htm" contains three links. The source code of the links:
    <a href ="tryhtml_frame_a.htm" target ="showframe”>Frame a</a><br>
    <a href ="tryhtml_frame_b.htm" target ="showframe”>Frame b</a><br>
    <a href ="tryhtml_frame_c.htm" target ="showframe”>Frame c</a>
    The second frame will show the linked document.
    <html>
    <frameset cols="120,*”>
    <frame src="tryhtml_contents.htm”>
    <frame src="tryhtml_frame_a.htm"
    name="showframe”>
    </frameset>
    </html>
    Inline frame
    This example demonstrates how to create an inline frame (a frame inside an HTML page).
    <html>
    <body>
    <iframe
    src ="default.asp”>
    </iframe>
    <p>Some older browsers don't support iframes.</p>
    <p>If they don't, the iframe will not be visible.</p>

    </body>
    </html>
    Jump to a specified section within a frame
    This example demonstrates two frames. One of the frames has a source to a specified section in a file. The specified section is made with <a name="C10”> in the "link.htm" file.
    <html>
    <frameset cols="20%,80%”>
    <frame src="tryhtml_frame_a.htm”>
    <frame src="link.htm#C10”>
    </frameset>
    </html>
    Jump to a specified section with frame navigation
    This example demonstrates two frames. The navigation frame (content.htm) to the left contains a list of links with the second frame (link.htm) as a target. The second frame shows the linked document.
    One of the links in the navigation frame is linked to a specified section in the target file. The HTML code in the file "content.htm" looks like this:
    <a href ="link.htm" target ="showframe”>Link without Anchor</a><br> <a href ="link.htm#C10" target ="showframe”>Link with Anchor</a>.
    <html>
    <frameset cols="180,*”>
    <frame src="content.htm”>
    <frame src="link.htm" name="showframe”>
    </frameset>
    </html>
    Frame Tags
    Tag Description
    <frameset>
    Defines a set of frames
    <frame>
    Defines a sub window (a frame)
    <noframes>
    Defines a noframe section for browsers that do not handle frames
    <iframe>
    Defines an inline sub window (frame)

    9-HTML Tables
    Tables
    Tables are defined with the <table> tag. A table is divided into rows (with the <tr> tag), & each row is divided into data cells (with the <td> tag). The letters td stands for "table data," which is the content of a data cell. A data cell can contain text, images, lists, paragraphs, forms, horizontal rules, tables etc.
    <table border="1”>
    <tr>
    <td>row 1, cell 1</td>
    <td>row 1, cell 2</td>
    </tr>
    <tr>
    <td>row 2, cell 1</td>
    <td>row 2, cell 2</td>
    </tr>
    </table>
    How it looks in a browser:
    row 1, cell 1 row 1, cell 2
    row 2, cell 1 row 2, cell 2
    ________________________________________
    Tables and the Border Attribute
    If you do not specify a border attribute the table will be displayed without any borders. Sometimes this can be useful, but most of the time, you want the borders to show.
    To display a table with borders, you will have to use the border attribute:
    <table border="1”>
    <tr>
    <td>Row 1, cell 1</td>
    <td>Row 1, cell 2</td>
    </tr>
    </table>
    Headings in a Table
    Headings in a table are defined with the <th> tag.
    <table border="1”>
    <tr>
    <th>Heading</th>
    <th>Another Heading</th>
    </tr>
    <tr>
    <td>row 1, cell 1</td>
    <td>row 1, cell 2</td>
    </tr>
    <tr>
    <td>row 2, cell 1</td>
    <td>row 2, cell 2</td>
    </tr>
    </table>
    How it looks in a browser:
    Heading Another Heading
    row 1, cell 1 row 1, cell 2
    row 2, cell 1 row 2, cell 2
    Empty Cells in a Table :Table cells with no content are not displayed very well in most browsers.
    <table border="1”>
    <tr>
    <td>row 1, cell 1</td>
    <td>row 1, cell 2</td>
    </tr>
    <tr>
    <td>row 2, cell 1</td>
    <td></td>
    </tr>
    </table>
    How it looks in a browser:
    row 1, cell 1 row 1, cell 2
    row 2, cell 1
    Note that the borders around the empty table cell are missing.
    To avoid this, add a non-breaking space ( ) to empty data cells, to make the borders visible:
    <table border="1”>
    <tr>
    <td>row 1, cell 1</td>
    <td>row 1, cell 2</td>
    </tr>
    <tr>
    <td>row 2, cell 1</td>
    <td> </td>
    </tr>
    </table>
    How it looks in a browser:
    row 1, cell 1 row 1, cell 2
    row 2, cell 1
    Basic Notes - Useful Tips
    The <thead>,<tbody> and <tfoot> elements are seldom used, because of bad browser support. Expect this to change in future versions of XHTML.
    Examples
    This example demonstrates how to create tables in an HTML document.
    <html>
    <body>
    <p>
    Each table starts with a table tag.
    Each table row starts with a tr tag.
    Each table data starts with a td tag.
    </p>
    <h4>One column:</h4>
    <table border="1”>
    <tr>
    <td>100</td>
    </tr>
    </table>
    <h4>One row and three columns:</h4>
    <table border="1”>
    <tr>
    <td>100</td>
    <td>200</td>
    <td>300</td>
    </tr>
    </table>
    <h4>Two rows and three columns:</h4>
    <table border="1”>
    <tr>
    <td>100</td>
    <td>200</td>
    <td>300</td>
    </tr>
    <tr>
    <td>400</td>
    <td>500</td>
    <td>600</td>
    </tr>
    </table>
    </body>
    </html>
    Table borders
    This example demonstrates different table borders.
    <html>
    <body>
    <h4>With a normal border:</h4>
    <table border="1”>
    <tr>
    <td>First</td>
    <td>Row</td>
    </tr>
    <tr>
    <td>Second</td>
    <td>Row</td>
    </tr>
    </table>
    <h4>With a thick border:</h4>
    <table border="8”>
    <tr>
    <td>First</td>
    <td>Row</td>
    </tr>
    <tr>
    <td>Second</td>
    <td>Row</td>
    </tr>
    </table>
    <h4>With a very thick border:</h4>
    <table border="15”>
    <tr>
    <td>First</td>
    <td>Row</td>
    </tr>
    <tr>
    <td>Second</td>
    <td>Row</td>
    </tr>
    </table>
    </body>
    </html>

    More Examples
    Table with no border
    This example demonstrates a table with no borders.
    <html>
    <body>
    <h4>This table has no borders:</h4>
    <table>
    <tr>
    <td>100</td>
    <td>200</td>
    <td>300</td>
    </tr>
    <tr>
    <td>400</td>
    <td>500</td>
    <td>600</td>
    </tr>
    </table>
    <h4>And this table has no borders:</h4>
    <table border="0”>
    <tr>
    <td>100</td>
    <td>200</td>
    <td>300</td>
    </tr>
    <tr>
    <td>400</td>
    <td>500</td>
    <td>600</td>
    </tr>
    </table>
    </body>
    </html>

    Empty cells:This example demonstrates how to use " " to handle cells that have no content.
    <html>
    <body>
    <table border="1”>
    <tr>
    <td>Some text</td>
    <td>Some text</td>
    </tr>
    <tr>
    <td></td>
    <td>Some text</td>
    </tr>
    </table>
    <p>
    As you can see, one of the cells has no border. That is because it is empty. Try to insert a space in the cell. Still it has no border.
    </p>
    <p>
    The trick is to insert a no-breaking space in the cell.
    </p>
    <p>No-breaking space is a character entity. If you don't know what a character entity is, read the chapter about it.
    </p>
    <p>The no-breaking space entity starts with an ampersand ("&"),
    then the letters "nbsp", and ends with a semicolon (";")
    </p>
    <p>
    </p>
    </body>
    </html>
    Table with a caption
    This example demonstrates a table with a caption.
    <html>
    <body>
    <h4>
    This table has a caption,
    and a thick border:
    </h4>
    <table border="6”>
    <caption>My Caption</caption>
    <tr>
    <td>100</td>
    <td>200</td>
    <td>300</td>
    </tr>
    <tr>
    <td>400</td>
    <td>500</td>
    <td>600</td>
    </tr>
    </table>
    </body>
    </html>
    Table cells that span more than one row/column
    This example demonstrates how to define table cells that span more than one row or one column.
    <html>
    <body>
    <h4>Cell that spans two columns:</h4>
    <table border="1”>
    <tr>
    <th>Name</th>
    <th colspan="2”>Telephone</th>
    </tr>
    <tr>
    <td>Bill Gates</td>
    <td>555 77 854</td>
    <td>555 77 855</td>
    </tr>
    </table>
    <h4>Cell that spans two rows:</h4>
    <table border="1”>
    <tr>
    <th>First Name:</th>
    <td>Bill Gates</td>
    </tr>
    <tr>
    <th rowspan="2”>Telephone:</th>
    <td>555 77 854</td>
    </tr>
    <tr>
    <td>555 77 855</td>
    </tr>
    </table>
    </body>
    </html>
    Tags inside a table
    This example demonstrates how to display elements inside other elements.
    <html>
    <body>
    <table border="1”>
    <tr>
    <td>
    <p>This is a paragraph</p>
    <p>This is another paragraph</p>
    </td>
    <td>This cell contains a table:
    <table border="1”>
    <tr>
    <td>A</td>
    <td>B</td>
    </tr>
    <tr>
    <td>C</td>
    <td>D</td>
    </tr>
    </table>
    </td>
    </tr>
    <tr>
    <td>This cell contains a list
    <ul>
    <li>apples</li>
    <li>bananas</li>
    <li>pineapples</li>
    </ul>
    </td>
    <td>HELLO</td>
    </tr>
    </table>
    </body>
    </html>

    Cell padding
    This example demonstrates how to use cellpadding to create more white space between the cell content and its borders.
    <html>
    <body>
    <h4>Without cellpadding:</h4>
    <table border="1”>
    <tr>
    <td>First</td>
    <td>Row</td>
    </tr>
    <tr>
    <td>Second</td>
    <td>Row</td>
    </tr>
    </table>
    <h4>With cellpadding:</h4>
    <table border="1"
    cellpadding="10”>
    <tr>
    <td>First</td>
    <td>Row</td>
    </tr>
    <tr>
    <td>Second</td>
    <td>Row</td>
    </tr>
    </table>
    </body>
    </html>
    Cell spacing
    This example demonstrates how to use cellspacing to increase the distance between the cells.
    <html>
    <body>
    <h4>Without cellspacing:</h4>
    <table border="1”>
    <tr>
    <td>First</td>
    <td>Row</td>
    </tr>
    <tr>
    <td>Second</td>
    <td>Row</td>
    </tr>
    </table>
    <h4>With cellspacing:</h4>
    <table border="1"
    cellspacing="10”>
    <tr>
    <td>First</td>
    <td>Row</td>
    </tr>
    <tr>
    <td>Second</td>
    <td>Row</td>
    </tr>
    </table>
    </body>
    </html>

    Add a background color or a background image to a table
    This example demonstrates how to add a background to a table.
    <html>
    <body>
    <h4>A background color:</h4>
    <table border="1"
    bgcolor="red”>
    <tr>
    <td>First</td>
    <td>Row</td>
    </tr>
    <tr>
    <td>Second</td>
    <td>Row</td>
    </tr>
    </table>
    <h4>A background image:</h4>
    <table border="1"
    background="../images/bgdesert.jpg”>
    <tr>
    <td>First</td>
    <td>Row</td>
    </tr>
    <tr>
    <td>Second</td>
    <td>Row</td>
    </tr>
    </table>
    </body>
    </html>
    Add a background color or a background image to a table cell
    This example demonstrates how to add a background to one or more table cells.
    <html>
    <body>
    <h4>Cell backgrounds:</h4>
    <table border="1”>
    <tr>
    <td bgcolor="red”>First</td>
    <td>Row</td>
    </tr>
    <tr>
    <td
    background="../images/bgdesert.jpg”>
    Second</td>
    <td>Row</td>
    </tr>
    </table>
    </body>
    </html>

    Align the content in a table cell
    This example demonstrates how to use the "align" attribute to align the content of cells, to create a "nice-looking" table.
    <html>
    <body>
    <table width="400" border="1”>
    <tr>
    <th align="left”>Money spent on....</th>
    <th align="right”>January</th>
    <th align="right”>February</th>
    </tr>
    <tr>
    <td align="left”>Clothes</td>
    <td align="right”>$241.10</td>
    <td align="right”>$50.20</td>
    </tr>
    <tr>
    <td align="left”>Make-Up</td>
    <td align="right”>$30.00</td>
    <td align="right”>$44.45</td>
    </tr>
    <tr>
    <td align="left”>Food</td>
    <td align="right”>$730.40</td>
    <td align="right”>$650.00</td>
    </tr>
    <tr>
    <th align="left”>Sum</th>
    <th align="right”>$1001.50</th>
    <th align="right”>$744.65</th>
    </tr>
    </table>
    </body>
    </html>

    The frame attribute
    This example demonstrates how to use the "frame" attribute to control the borders around the table.
    <html>
    <body>
    <p>
    If you see no frames around the
    tables in these examples, your
    browser is too old, or does
    not support it.
    </p>
    <h4>With frame="border":</h4>
    <table frame="border”>
    <tr>
    <td>First</td>
    <td>Row</td>
    </tr>
    <tr>
    <td>Second</td>
    <td>Row</td>
    </tr>
    </table>
    <h4>With frame="box":</h4>
    <table frame="box”>
    <tr>
    <td>First</td>
    <td>Row</td>
    </tr>
    <tr>
    <td>Second</td>
    <td>Row</td>
    </tr>
    </table>
    <h4>With frame="void":</h4>
    <table frame="void”>
    <tr>
    <td>First</td>
    <td>Row</td>
    </tr>
    <tr>
    <td>Second</td>
    <td>Row</td>
    </tr>
    </table>
    <h4>With frame="above":</h4>
    <table frame="above”>
    <tr>
    <td>First</td>
    <td>Row</td>
    </tr>
    <tr>
    <td>Second</td>
    <td>Row</td>
    </tr>
    </table>
    <h4>With frame="below":</h4>
    <table frame="below”>
    <tr>
    <td>First</td>
    <td>Row</td>
    </tr>
    <tr>
    <td>Second</td>
    <td>Row</td>
    </tr>
    </table>
    <h4>With frame="hsides":</h4>
    <table frame="hsides”>
    <tr>
    <td>First</td>
    <td>Row</td>
    </tr>
    <tr>
    <td>Second</td>
    <td>Row</td>
    </tr>
    </table>
    <h4>With frame="vsides":</h4>
    <table frame="vsides”>
    <tr>
    <td>First</td>
    <td>Row</td>
    </tr>
    <tr>
    <td>Second</td>
    <td>Row</td>
    </tr>
    </table>
    <h4>With frame="lhs":</h4>
    <table frame="lhs”>
    <tr>
    <td>First</td>
    <td>Row</td>
    </tr>
    <tr>
    <td>Second</td>
    <td>Row</td>
    </tr>
    </table>
    <h4>With frame="rhs":</h4>
    <table frame="rhs”>
    <tr>
    <td>First</td>
    <td>Row</td>
    </tr>
    <tr>
    <td>Second</td>
    <td>Row</td>
    </tr>
    </table>
    </body>
    </html>
    Table Tags
    Tag Description
    <table>
    Defines a table
    <th>
    Defines a table header
    <tr>
    Defines a table row
    <td>
    Defines a table cell
    <caption>
    Defines a table caption
    <colgroup>
    Defines groups of table columns
    <col>
    Defines the attribute values for one or more columns in a table
    <thead>
    Defines a table head
    <tbody>
    Defines a table body
    <tfoot>
    Defines a table footer

    10-HTML Lists
    HTML supports ordered, unordered and definition lists.
    Examples
    An unordered list
    An unordered list is a list of items. The list items are marked with bullets (typically small black circles). An unordered list starts with the <ul> tag. Each list item starts with the <li> tag.
    This example demonstrates an unordered list.
    <html>
    <body>
    <h4>An Unordered List:</h4>
    <ul>
    <li>Coffee</li>
    <li>Tea</li>
    <li>Milk</li>
    </ul>
    </body>
    </html>
    An ordered list
    An ordered list is also a list of items. The list items are marked with numbers. An ordered list starts with the <ol> tag. Each list item starts with the <li> tag.
    This example demonstrates an ordered list.
    <html>
    <body>
    <h4>An Ordered List:</h4>
    <ol>
    <li>Coffee</li>
    <li>Tea</li>
    <li>Milk</li>
    </ol>
    </body>
    </html>
    Inside a list item you can put paragraphs, line breaks, images, links, other lists, etc.
    Definition Lists
    A definition list is not a list of items. This is a list of terms and explanation of the terms.
    A definition list starts with the <dl> tag. Each definition-list term starts with the <dt> tag. Each definition-list definition starts with the <dd> tag.
    <dl>
    <dt>Coffee</dt>
    <dd>Black hot drink</dd>
    <dt>Milk</dt>
    <dd>White cold drink</dd>
    </dl>
    Here is how it looks in a browser:
    Coffee
    Black hot drink
    Milk
    White cold drink
    Inside a definition-list definition (the <dd> tag) you can put paragraphs, line breaks, images, links, other lists, etc.
    More Examples
    Different types of ordered lists
    This example demonstrates different types of ordered lists.
    <html>
    <body>
    <h4>Numbered list:</h4>
    <ol>
    <li>Apples</li>
    <li>Bananas</li>
    <li>Lemons</li>
    <li>Oranges</li>
    </ol>
    <h4>Letters list:</h4>
    <ol type="A”>
    <li>Apples</li>
    <li>Bananas</li>
    <li>Lemons</li>
    <li>Oranges</li>
    </ol>
    <h4>Lowercase letters list:</h4>
    <ol type="a”>
    <li>Apples</li>
    <li>Bananas</li>
    <li>Lemons</li>
    <li>Oranges</li>
    </ol>
    <h4>Roman numbers list:</h4>
    <ol type="I”>
    <li>Apples</li>
    <li>Bananas</li>
    <li>Lemons</li>
    <li>Oranges</li>
    </ol>
    <h4>Lowercase Roman numbers list:</h4>
    <ol type="i”>
    <li>Apples</li>
    <li>Bananas</li>
    <li>Lemons</li>
    <li>Oranges</li>
    </ol>
    </body>
    </html>

    Different types of unordered Lists
    This example demonstrates different types of unordered lists.
    <html>
    <body>
    <h4>Disc bullets list:</h4>
    <ul type="disc”>
    <li>Apples</li>
    <li>Bananas</li>
    <li>Lemons</li>
    <li>Oranges</li>
    </ul>
    <h4>Circle bullets list:</h4>
    <ul type="circle”>
    <li>Apples</li>
    <li>Bananas</li>
    <li>Lemons</li>
    <li>Oranges</li>
    </ul>
    <h4>Square bullets list:</h4>
    <ul type="square”>
    <li>Apples</li>
    <li>Bananas</li>
    <li>Lemons</li>
    <li>Oranges</li>
    </ul>
    </body>
    </html>
    Nested list This example demonstrates how you can nest lists.
    <html>
    <body>
    <h4>A nested List:</h4>
    <ul>
    <li>Coffee</li>
    <li>Tea
    <ul>
    <li>Black tea</li>
    <li>Green tea</li>
    </ul>
    </li>
    <li>Milk</li>
    </ul>
    </body>
    </html>
    List Tags
    Tag Description
    <ol>
    Defines an ordered list
    <ul>
    Defines an unordered list
    <li>
    Defines a list item
    <dl>
    Defines a definition list
    <dt>
    Defines a definition term
    <dd>
    Defines a definition description
    <dir>
    Deprecated. Use <ul> instead
    <menu>
    Deprecated. Use <ul> instead

    11-HTML Forms and Input
    Forms
    HTML Forms are used to select different kinds of user input.
    A form is an area that can contain form elements.
    Form elements are elements that allow the user to enter information (like text fields, textarea fields, drop-down menus, radio buttons, checkboxes, etc.) in a form.
    A form is defined with the <form> tag.
    <form>
    <input>
    <input>
    </form>
    Input
    The most used form tag is the <input> tag. The type of input is specified with the type attribute. The most commonly used input types are explained below.
    Text Fields
    Text fields are used when you want the user to type letters, numbers, etc. in a form.
    <form>
    First name:
    <inputtype="text" name="firstname”>
    <br>
    Last name:
    <inputtype="text" name="lastname”>
    </form>
    How it looks in a browser:
    First name:
    Last name:
    Note that the form itself is not visible. Also note that in most browsers, the width of the text field is 20 characters by default.
    Radio Buttons
    Radio Buttons are used when you want the user to select one of a limited number of choices.
    <form>
    <inputtype="radio" name="sex" value="male”> Male
    <br>
    <inputtype="radio" name="sex" value="female”> Female
    </form>
    How it looks in a browser:
    Male
    Female
    Note that only one option can be chosen.
    Checkboxes
    Checkboxes are used when you want the user to select one or more options of a limited number of choices.
    <form>
    <inputtype="checkbox" name="bike”>
    I have a bike
    <br>
    <inputtype="checkbox" name="car”>
    I have a car
    </form>
    How it looks in a browser:
    I have a bike
    I have a car
    The Form's Action Attribute and the Submit Button
    When the user clicks on the "Submit" button, the content of the form is sent to another file. The form's action attribute defines the name of the file to send the content to. The file defined in the action attribute usually does something with the received input.
    <form name="input" action="html_form_action.asp"
    method="get”>
    Username:
    <inputtype="text" name="user”>
    <inputtype="submit" value="Submit”>
    </form>
    How it looks in a browser:
    Username:
    If you type some characters in the text field above, and click the "Submit" button, you will send your input to a page called "html_form_action.asp". That page will show you the received input.
    Examples
    Text fields
    This example demonstrates how to create text fields on a HTML page. A user can write text in a text field.
    <html>
    <body>
    <form>
    First name:
    <inputtype="text" name="firstname”>
    <br>
    Last name:
    <inputtype="text" name="lastname”>
    </form>
    </body>
    </html>
    Password fields
    This example demonstrates how to create a password field on a HTML page.
    <html>
    <body>
    <form>
    Username:
    <inputtype="text" name="user”>
    <br>
    Password:
    <inputtype="password" name="password”>
    </form>
    <p>
    Note that when you type characters in a password field, the browser displays asterisks or bullets instead of the characters.
    </p>
    </body>
    </html>
    More Examples
    Checkboxes
    This example demonstrates how to create check-boxes on a HTML page. A user can select or unselect a checkbox.
    <html>
    <body>
    <form>
    I have a bike:
    <input type="checkbox" name="Bike”>
    <br>
    I have a car:
    <input type="checkbox" name="Car”>
    </form>
    </body>
    </html>
    Radiobuttons
    This example demonstrates how to create radio-buttons on a HTML page.
    <html>
    <body>
    <form>
    Male:
    <input type="radio" checked
    name="Sex" value="male”>
    <br>
    Female:
    <input type="radio"
    name="Sex" value="female”>
    </form>
    <p>
    When a user clicks on a radio-button, the button becomes checked, and all other buttons with the same name become unchecked
    </p>
    </body>
    </html>
    Simple drop down box
    This example demonstrates how to create a simple drop-down box on a HTML page. A drop-down box is a selectable list.
    <html>
    <body>
    <form>
    <selectname="cars”>
    <option value="volvo”>Volvo
    <option value="saab”>Saab
    <option value="fiat”>Fiat
    <option value="audi”>Audi
    </select>
    </form>
    </body>
    </html>
    Textarea
    This example demonstrates how to create a text-area (a multi-line text input control). A user can write text in the text-area. In a text-area you can write an unlimited number of characters.
    <html>
    <body>
    <p>
    This example can not be edited
    because our editor uses a textarea
    for input,
    and your browser does not allow
    a textarea inside a textarea.
    </p>
    <textarea rows="10" cols="30">
    The cat was playing in the garden.
    </textareaa>
    </body>
    <html>
    Create a button
    This example demonstrates how to create a button. On the button you can define your own text.
    <html>
    <body>
    <form>
    <inputtype="button" value="Hello world!”>
    </form>
    </body>
    </html>
    Fieldset around data
    This example demonstrates how to draw a border with a caption around your data.
    <html>
    <body>
    <fieldset>
    <legend>
    Health information:
    <legend>
    <form>
    Height <inputtype="text" size="3”>
    Weight <inputtype="text" size="3”>
    </form>
    </fieldset>
    <p>
    If there is no border around the input form, your browser is too old.
    </p>
    </body></html>
    Form Examples
    Form with input fields and a submit button
    This example demonstrates how to add a form to a page. The form contains two input fields and a submit button.
    <html>
    <body>
    <form name="input" action="html_form_action.asp"
    method="get”>
    Enter your first name:
    <input type="text" name="FirstName"
    value="Mickey”>
    <br>Enter your last name:
    <input type="text" name="LastName" value="Mouse”>
    <br>
    <input type="submit" value="Submit”>
    </form>
    <p>
    If you click the "Submit" button, you will
    send your input to a new page called html_form_action.asp.
    </p>
    </body>
    </html>
    Send e-mail from a form
    This example demonstrates how to send e-mail from a form.
    <html>
    <body>
    <form action="MAILTO:[email protected]"; method="post" enctype="text/plain”>
    <h3>This form sends an e-mail to W3Schools.</h3>
    Name:<br>
    <input type="text" name="name"
    value="yourname" size="20”>
    <br>
    Mail:<br>
    <input type="text" name="mail"
    value="yourmail" size="20”>
    <br>
    Comment:<br>
    <input type="text" name="comment"
    value="yourcomment" size="40”>
    <br><br>
    <input type="submit" value="Send”>
    <input type="reset" value="Reset”>
    </form>
    </body>
    </html>
    Form Tags
    Tag Description
    <form>
    Defines a form for user input
    <input>
    Defines an input field
    <textarea>
    Defines a text-area (a multi-line text input control)
    <label>
    Defines a label to a control
    <fieldset>
    Defines a fieldset
    <legend>
    Defines a caption for a fieldset
    <select>
    Defines a selectable list (a drop-down box)
    <optgroup>
    Defines an option group
    <option>
    Defines an option in the drop-down box
    <button>
    Defines a push button
    <isindex> Deprecated. Use <input> instead
    12-HTML Images
    With HTML you can display images in a document.
    The Image Tag and the Src Attribute
    In HTML, images are defined with the <img> tag.
    The <img> tag is empty, which means that it contains attributes only and it has no closing tag.
    To display an image on a page, you need to use the src attribute. Src stands for "source". The value of the src attribute is the URL of the image you want to display on your page.
    The syntax of defining an image:
    <img src="url”>
    The URL points to the location where the image is stored. An image named "boat.gif" located in the directory "images" on "www.w3schools.com" has the URL: .
    The browser puts the image where the image tag occurs in the document. If you put an image tag between two paragraphs, the browser shows the first paragraph, then the image, and then the second paragraph.
    The Alt Attribute
    The alt attribute is used to define an "alternate text" for an image. The value of the alt attribute is an author-defined text:
    <img src="boat.gif" alt="Big Boat”>
    The "alt" attribute tells the reader what he or she is missing on a page if the browser can't load images. The browser will then display the alternate text instead of the image. It is a good practice to include the "alt" attribute for each image on a page, to improve the display and usefulness of your document for people who have text-only browsers.
    Basic Notes - Useful Tips
    If an HTML file contains ten images - eleven files are required to display the page right. Loading images take time, so my best advice is: Use images carefully.
    Examples
    Insert images
    This example demonstrates how to display images in your Web page.
    <html>
    <body>
    <p>
    An image:
    <img src="constr4.gif"
    width="144" height="50”>
    </p>
    <p>
    A moving image:
    <img src="hackanm.gif"
    width="48" height="48”>
    </p>
    <p>
    Note that the syntax of inserting
    a moving image is no different from t
    hat of a non-moving image.
    </p>
    </body>
    </html>
    Insert images from different locations
    This example demonstrates how to display images from another folder or another server in your Web page.
    <html>
    <body>
    <p>
    An image from another folder:
    <img src="../images/netscape.gif"
    width="33" height="32”>
    </p>
    <p>
    An image from W3Schools:
    <img src="../images/ie.gif" width="73" height="68”>
    </p>
    </body>
    </html>
    More Examples
    Background image
    This example demonstrates how to add a background image to an HTML page.
    <html>
    <body background="background.jpg”>
    <h3>Look: A background image!</h3>
    <p>Both gif and jpg files can be used as HTML backgrounds.</p>
    <p>If the image is smaller than the page, the image will repeat itself.</p>
    </body>
    </html>
    Aligning images
    This example demonstrates how to align an image within the text.
    <html>
    <body>
    <p>
    An image
    <img src ="../images/xhtml.gif"
    align="bottom" width="100" height="50”>
    in the text
    </p>
    <p>
    An image
    <img src ="../images/xhtml.gif"
    align="middle" width="100" height="50”>
    in the text
    </p>
    <p>
    An image
    <img src ="../images/xhtml.gif"
    align="top" width="100" height="50”>
    in the text
    </p>
    <p>Note that bottom alignment is the
    default alignment</p>
    <p>
    An image
    <img src ="../images/xhtml.gif"
    width="100" height="50”>
    in the text
    </p>
    <p>
    <img src ="../images/xhtml.gif"
    width="100" height="50”>
    An image before the text
    </p>
    <p>
    An image after the text
    <img src ="../images/xhtml.gif"
    width="100" height="50”>
    </p>
    </body>
    </html>
    Adjust images to different sizes
    This example demonstrates how to adjust images to different sizes.
    <html>
    <body>
    <p>
    <img src="../images/hackanm.gif"
    width="20" height="20”>
    </p>
    <p>
    <img src="../images/hackanm.gif"
    width="45" height="45”>
    </p>
    <p>
    <img src="../images/hackanm.gif"
    width="70" height="70”>
    </p>
    <p>
    You can make a picture larger or smaller changing the values in the "height" and "width" attributes of the img tag.
    </p>
    </body>
    </html>
    Display an alternate text for an image
    This example demonstrates how to display an alternate text for an image. The "alt" attribute tells the reader what he or she is missing on a page if the browser can't load images. It is a good practice to include the "alt" attribute for each image on a page.
    <html>
    <body>
    <img src="../images/goleft.gif" alt="Go Left" width="32" height="32”>
    <p>
    Text-only browsers will only display the text in the "alt" attribute, which is "Go Left".
    Note that if you hold the mouse pointer over the image it will display the text.
    </p>
    </body>
    </html>

    Make a hyperlink of an image
    This example demonstrates how to use an image as a link.
    Discussed before.
    Create an image map
    This example demonstrates how to create an image map, with clickable regions. Each of the regions is a hyperlink.
    <html>
    <body>
    <p>
    Click on one of the planets to watch it closer:
    </p>
    <img src="../images/planets.gif"
    width="145" height="126"
    usemap="#planetmap”>
    <map id="planetmap" name="planetmap”>
    <area shape="rect"
    coords="0,0,82,126"
    alt="Sun"
    href="sun.htm”>
    <area shape="circle"
    coords="90,58,3"
    alt="Mercury"
    href="mercur.htm”>
    <area shape="circle"
    coords="124,58,8"
    alt="Venus"
    href="venus.htm”>
    </map>
    <p>
    <b>Note:</b> The <b>usemap</b> attribute in <image> refers to the <b>id</b> or <b>name</b> (browser dependant) attribute in
    <map>, therefore we have added both the id and name attributes to <map>.
    </p>
    </body>
    </html>
    Turn an image into an image map
    This example demonstrates how to turn an image into an image map. You will see that if you move the mouse over the image, the coordinates will be displayed on the status bar.
    <html>
    <body>
    <p>
    Move the mouse over the image, and look at the status bar to see how the
    coordinates change.
    </p>
    <p>
    <a href="tryhtml_ismap.htm”>
    <img src="../images/planets.gif"
    ismap width="146" height="126”>
    </a>
    </p>
    </body>
    </html>

    Image Tags
    Tag Description
    <img>
    Defines an image
    <map>
    Defines an image map
    <area>
    Defines an area inside an image map
    13-HTML Backgrounds
    A good background can make a Web site look really great.
    Background
    The background attribute sets the background to an image. The value of this attribute is the URL of the image you want to use. If the image is smaller than the browser window, the image will repeat itself until it fills the entire browser window.
    <body background="clouds.gif”>
    <body background=" ”>
    The URL can be relative (as in the first line above) or absolute (as in the second line above).
    Note: If you want to use a background image, you should keep in mind:
    • Will the background image increase the loading time too much? Tip: Image files should be maximum 10k
    • Will the background image look good with other images on the page?
    • Will the background image look good with the text colors on the page?
    • Will the background image look good when it is repeated on the page?
    • Will the background image take away the focus from the text?
    Basic Notes - Useful Tips
    The bgcolor, background, and the text attributes in the <body> tag are deprecated in the latest versions of HTML (HTML 4 and XHTML). The World Wide Web Consortium (W3C) has removed these attributes from its recommendations. In future versions of HTML, style sheets (CSS) will be used to define the layout and display properties of HTML elements.
    Few of the most visited web sites use background images.
    The most used background colors are: white, black and gray.
    Examples
    Good background and text color
    An example of a background color and a text color that makes the text on the page easy to read.
    <html>
    <body bgcolor="#d0d0d0”>
    <p>
    This is a paragraph. This is a paragraph.
    This is a paragraph. This is a paragraph.
    This is a paragraph.
    </p>
    <p>
    This is another paragraph. This is another
    paragraph. This is another paragraph.
    This is another paragraph.
    </p>
    </body>
    </html>
    Bad background and text color
    An example of a background color and a text color that makes the text on the page difficult to read.
    <html>
    <body bgcolor="#ffffff" text="yellow”>
    <p>This is a paragraph. This is a paragraph. This is a paragraph. This is a paragraph. This is a paragraph.</p>
    <p>This is another paragraph. This is another paragraph. This is another paragraph. This is another paragraph.
    </p>
    </body>
    </html>
    Backgrounds
    The <body> tag has two attributes where you can specify backgrounds. The background can be a color or an image.
    Bgcolor
    The bgcolor attribute sets the background to a color. The value of this attribute can be a hexadecimal number, an RGB value, or a color name.
    <body bgcolor="#000000”>
    <body bgcolor="rgb(0,0,0)”>
    <body bgcolor="black”>
    The lines above all set the background color to black.[/align]
    ãä áã íãÊ ÈÇáÓíÝ ãÇÊ ÈÛíÑå *** ÊÚÏÏÊ ÇáÇÓÈÇÈ æÇáãæÊ æÇÍÏ

    ÝÇÚãá áÏäíÇß ßÇäß ÊÚíÔ ÇÈÏÇ æÇÚãá áÇÎÑÊß ßÇäß ÊãæÊ ÛÏÇ...

  • #2
    ÇÑÌæ Çäí ãÇ ØæáÊ ãÚÇßã
    ãä áã íãÊ ÈÇáÓíÝ ãÇÊ ÈÛíÑå *** ÊÚÏÏÊ ÇáÇÓÈÇÈ æÇáãæÊ æÇÍÏ

    ÝÇÚãá áÏäíÇß ßÇäß ÊÚíÔ ÇÈÏÇ æÇÚãá áÇÎÑÊß ßÇäß ÊãæÊ ÛÏÇ...

    تعليق


    • #3
      ÇáÓáÇã Úáíßã

      ÇáÃÎ ÇáÝÇÖá snakegaer

      ÇÔßÑß Úáì ãÌåæÏß , ÇäãÇ ãä ÇáÚÓíÑ Çä íÓÊÝíÏ ãäå ÃÍÏ æåæ ÈåÐÇ

      ÇáÔßá .. ßãÇ Ãääí ÕÇÏÝÊ ÚÏÏÇ ãä ÇáÃßæÇÏ ãßÊæÈÉ ÈÔßá

      ãÚßæÓ ããÇ íÚäí Ãä ÇáÊØÈíÞ ÚÈÑ ÈÑäÇãÌ ÇáãÝßÑÉ áä

      íßæä ãÌÏíÇð .

      ÔßÑÇ áß
      http://www.omanlover.org/vb/uploaded/alfahad.jpg

      تعليق


      • #4
        ÇáãÔßáÉ ÕÚÈ ÇáÊÚÏíá Ýí ÇáãäÊÏì
        ãä áã íãÊ ÈÇáÓíÝ ãÇÊ ÈÛíÑå *** ÊÚÏÏÊ ÇáÇÓÈÇÈ æÇáãæÊ æÇÍÏ

        ÝÇÚãá áÏäíÇß ßÇäß ÊÚíÔ ÇÈÏÇ æÇÚãá áÇÎÑÊß ßÇäß ÊãæÊ ÛÏÇ...

        تعليق

        يعمل...
        X