www.smwebtechservices.com

HTML Codes


Sometimes a website will not work because of simple HTML codes are missing. Here are a few tips that will fix a problem
fast that might otherwise take hours to figure out.

The email is not working although everything regarding the email has been set up on the host end. Simply go into the HTML search codes in your HTML editor and look in the codes where you see the codes for the email. The email HTML codes should look like the following example to work right:
<a href="mailto:service@smwebtechservices.com">Contact Us</a>
So we can no just simply put service@smwebtechservices.com because it will not work and you will get the message "page not found."



PageRank Recovery


We all come across the message 
"Error 404" regularly while online. It has nothing to do with computer errors but many will try to sell you computer repair programs supposedly to fix it. What is going on? This error message means the link is broken because the page has changed name, site structure has changed, or been taken down so the link needs to be fixed by the site's owner or webmaster.

However, it can be a huge task to find broken links on a website. Luckily there are great tools available such as the 
PageRank Recovery Tool that make it easier. Once you find the broken links go to the Control Panel of the host for your website and look for the URL Redirect. Then place the broken link in the "Redirect this URL" area and "To this URL" is were you enter the URL link to where you want the site to go to. When you are done remember to save it.



Free HTML Editor several listed there and free templates


HTML TAGS

H1 -  Level 1 Heading
H1 code looks like this <h1> </h1>. It is the most important header in the document and often has the title in it. It really should be rendered more prominently than any other header. Often it seems to have the same content as the Title tag, but that may not necesarily be so. Don't leave it blank because search engine spiders seem to give words appearing within the headers more importance. Headers may affect font size, align attributes and outline. Headers should be used in hirerarchical order so always start with H1 then H2. etc.,

H2 - Level 2 Heading
H2 code looks like this <h2><h2>. The level 2 heading is the second most important header in a document. Don't leave it blank.

H3 - Level 3 Heading

H3 code looks like this <h3><h3>.  The level 3 heading is the third most important header in a doucment. It is often used to mark up sections within a chaper in a document. Don't leave it blank.

H4 - Level 4 Heading

H4 code looks like this <h4><h4>. The level 4 heading is the forth most
important header in a document. It is often used to mark up subsections within a document.


H5 - Level 5 Heading

H5 code looks like this <h5><h5>. The level 5 is the second least important header in a document. Since it is often rendered in a small font, it is not used very often. It should be used to divide sections within H5.

H6 - Level 6 Heading

H6 code looks like this <h6><h6>. The level 6 is the least important header in a doucment. It is often rendered in a small font, it is not used very often because it is the smallest heading in font size. It should be used to divide sections within H6.



HTML Codes For  HTML Basic Document

<html>
<head>
<title>the document's title goes here </title>
</head>
<body>
visible text goes here
</body>
</html>


Inserting Image

In HTML, images are defined with the <img> tag.
<img src="cat.gif"  alt="Big Cat" />



HTML Table


Tag Description DTD
<!--...--> Defines a comment
<!--This is a comment. Comments are not displayed in the browser-->
STF
<!DOCTYPE>  Defines the document type - for example:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.smwebtechservices.com/TR/xhtml1/DTD/xhtml1-transitional.dtd">
STF
<a> Defines an anchor
Example: <a href="http://www.smwebtechservices.com">Visit smwebtech.com!</a>
STF
<abbr> Defines an abbreviation
Example: The <abbr title="World Health Organization">WHO</abbr> was founded in 1948
STF
<acronym> Defines an acronym
Example: Can I get this <acronym title="as soon as possible">ASAP</acronym>?
STF
<address> Defines contact information for the author/owner of a document
Example: <address>
Written by W3Schools.com<br />
<a href="mailto:us@example.org">Email us</a><br />
Address: Box 564, Disneyland<br />
Phone: +12 34 56 78
</address>
STF
<applet> Deprecated. Defines an embedded applet
Example: <applet code="Bubbles.class" width="350" height="350">
Java applet that draws animated bubbles.
</applet>
TF
<area /> Defines an area inside an image-map
Example:
<img src ="planets.gif" width="145" height="126" alt="Planets" usemap ="#planetmap" />

<map name="planetmap">
  <area shape="rect" coords="0,0,82,126" href="sun.htm" alt="Sun" />
  <area shape="circle" coords="90,58,3" href="mercur.htm" alt="Mercury" />
  <area shape="circle" coords="124,58,8" href="venus.htm" alt="Venus" />
</map>
STF
<b> Defines bold text
Example: <tt>Teletype text</tt>
<i>Italic text</i>
<b>Bold text</b>
<big>Big text</big>
<small>Small text</small>
STF
<base /> Defines a default address or a default target for all links on a page. Example:
<head>
<base href="http://www.smwebtechservices.com" /target>
<base target="_blank" />
</head>

<body>
<img src="stickwoman.gif" />
<a href="http://www.smwebtechservices.com">smwebtech</a>
</body>
STF
<basefont /> Deprecated. Defines a default font, color, or size for the text in a page. Example:
<head>
<basefont color="red" size="5" />
</head>

<body>
<h1>This is a header</h1>
<p>This is a paragraph</p>
</body>
TF
<bdo> Defines the text direction
Example: <bdo dir="rtl">Here is some Hebrew text!</bdo>
STF
<big> Defines big text
Example: <tt>Teletype text</tt>
<i>Italic text</i>
<b>Bold text</b>
<big>Big text</big>
<small>Small text</small>
STF
<blockquote> Defines a long quotation. Example:
<blockquote>
Here is a long quotation here is a long quotation here is a long quotation here is a long quotation here is a long quotation here is a long quotation here is a long quotation here is a long quotation here is a long quotation.
</blockquote>
STF
<body> Defines the document's body. Example:
<html>
<head>
<title>Title of the document</title>
</head>

<body>
The content of the document......
</body>

</html>
STF
<br /> Defines a single line break
Example: This text contains<br />a line break.
STF
<button> Defines a push button
Example: <button type="button">Click Me!</button>
STF
<caption> Defines a table caption. Example:
<table border="1">
  <caption>Monthly savings</caption>
  <tr>
    <th>Month</th>
    <th>Savings</th>
  </tr>
  <tr>
    <td>January</td>
    <td>$100</td>
  </tr>
</table>
STF
<center> Deprecated. Defines centered text
Example: <center>This text will be centered.</center>
TF
<cite> Defines a citation. Example:
<em>Emphasized text</em>
<strong>Strong text</strong>
<dfn>Definition term</dfn>
<code>Computer code text</code>
<samp>Sample computer code text</samp>
<kbd>Keyboard text</kbd>
<var>Variable</var>
<cite>Citation</cite>
STF
<code> Defines computer code text. Example:
<em>Emphasized text</em>
<strong>Strong text</strong>
<dfn>Definition term</dfn>
<code>Computer code text</code>
<samp>Sample computer code text</samp>
<kbd>Keyboard text</kbd>
<var>Variable</var>
<cite>Citation</cite>
STF
<col /> Defines attribute values for one or more columns in a table
Example: <table width="100%" border="1">
  <col align="left" />
  <col align="left" />
  <col align="right" />
  <tr>
    <th>ISBN</th>
    <th>Title</th>
    <th>Price</th>
  </tr>
  <tr>
    <td>3476896</td>
    <td>My first HTML</td>
    <td>$53</td>
  </tr>
</table>
STF

<colgroup>

Defines a group of columns in a table for formatting.
Example:
<table width="100%" border="1">
  <colgroup span="2" align="left"></colgroup>
  <colgroup align="right" style="color:#0000FF;"></colgroup>
  <tr>
    <th>ISBN</th>
    <th>Title</th>
    <th>Price</th>
  </tr>
  <tr>
    <td>3476896</td>
    <td>My first HTML</td>
    <td>$53</td>
  </tr>
</table>
STF
<dd> Defines a description of a term in a definition list.
Example: <dl>
  <dt>Coffee</dt>
    <dd>- black hot drink</dd>
  <dt>Milk</dt>
    <dd>- white cold drink</dd>
</dl>
STF
<del> Defines deleted text.
Example: <p>My favorite color is <del>blue</del> <ins>red</ins>!</p>
STF
<dfn> Defines a definition term. Example:
<em>Emphasized text</em>
<strong>Strong text</strong>
<dfn>Definition term</dfn>
<code>Computer code text</code>
<samp>Sample computer code text</samp>
<kbd>Keyboard text</kbd>
<var>Variable</var>
<cite>Citation</cite>
STF
<dir> Deprecated. Defines a directory list.
Example: <dir>
  <li>html</li>
  <li>xhtml</li>
  <li>css</li>
</dir>
TF
<div> Defines a section in a document.
Example: <div style="color:#00FF00">
  <h3>This is a header</h3>
  <p>This is a paragraph.</p>
</div>
STF
<dl> Defines a definition list. Example:
<dl>
  <dt>Coffee</dt>
    <dd>- black hot drink</dd>
  <dt>Milk</dt>
    <dd>- white cold drink</dd>
</dl>
STF
<dt> Defines a term (an item) in a definition list. Example:
<dl>
  <dt>Coffee</dt>
    <dd>- black hot drink</dd>
  <dt>Milk</dt>
    <dd>- white cold drink</dd>
</dl>
STF
<em> Defines emphasized text. Example:
 <em>Emphasized text</em>
<strong>Strong text</strong>
<dfn>Definition term</dfn>
<code>Computer code text</code>
<samp>Sample computer code text</samp>
<kbd>Keyboard text</kbd>
<var>Variable</var>
<cite>Citation</cite>
STF
<fieldset> Defines a border around elements in a form. Example:
<form>
  <fieldset>
    <legend>Personalia:</legend>
    Name: <input type="text" size="30" /><br />
    Email: <input type="text" size="30" /><br />
    Date of birth: <input type="text" size="10" />
  </fieldset>
</form>
STF
<font> Deprecated. Defines font, color, and size for text. Example:
<font size="3" color="red">This is some text!</font>
<font size="2" color="blue">This is some text!</font>
<font face="verdana" color="green">This is some text!</font>
TF
<form> Defines an HTML form for user input. Example:
<form action="form_action.asp" method="get">
  First name: <input type="text" name="fname" /><br />
  Last name: <input type="text" name="lname" /><br />
  <input type="submit" value="Submit" />
</form>
STF
<frame /> Defines a window (a frame) in a frameset. A simple 3 framed
page. Example
<html>

<frameset cols="25%,50%,25%">
  <frame src="frame_a.htm" />
  <frame src="frame_b.htm" />
  <frame src="frame_c.htm" />
</frameset>

</html>:
F
<frameset> Defines a set of frames. Example:
<html>

<frameset cols="25%,*,25%">
  <frame src="frame_a.htm" />
  <frame src="frame_b.htm" />
  <frame src="frame_c.htm" />
</frameset>

</html>
F
<h1> to <h6> Defines HTML headings. Example:
<h1>This is heading 1</h1>
<h2>This is heading 2</h2>
<h3>This is heading 3</h3>
<h4>This is heading 4</h4>
<h5>This is heading 5</h5>
<h6>This is heading 6</h6>

STF
<head> Defines information about the document. Example:
<html>
<head>
<title>Title of the document</title>
</head>

<body>
The content of the document......
</body>

</html>
STF
<hr /> Defines a horizontal line. Example:
<p>This is some text.</p>
<hr />
<p>This is some text.</p>
STF
<html> Defines an HTML document. Example:
<html>
<head>
<title>Title of the document</title>
</head>

<body>
The content of the document......
</body>

</html>
STF
<i> Defines italic text. Example:
<tt>Teletype text</tt>
<i>Italic text</i>
<b>Bold text</b>
<big>Big text</big>
<small>Small text</small>
STF
<iframe> Defines an inline frame. Example:
<iframe src="html_intro.asp" width="100%" height="300">
  <p>Your browser does not support iframes.</p>
</iframe>
TF
<img /> Defines an image. Example:
<img src="angry.gif" alt="Angry face" />
STF
<input /> Defines an input control. Example:
<form action="form_action.asp" method="get">
  First name: <input type="text" name="fname" /><br />
  Last name: <input type="text" name="lname" /><br />
  <input type="submit" value="Submit" />
</form>
STF
<ins> Defines inserted text. Example:
<p>My favorite color is <del>blue</del> <ins>red</ins>!</p>
STF
<isindex> Deprecated. Defines a searchable index related to a document TF
<kbd> Defines keyboard text. Example:
<em>Emphasized text</em>
<strong>Strong text</strong>
<dfn>Definition term</dfn>
<code>Computer code text</code>
<samp>Sample computer code text</samp>
<kbd>Keyboard text</kbd>
<var>Variable</var>
<cite>Citation</cite>
STF
<label> Defines a label for an input element. Example with two input fields and related labels:
<form>
  <label for="male">Male</label>
  <input type="radio" name="sex" id="male" />
  <br />
  <label for="female">Female</label>
  <input type="radio" name="sex" id="female" />
</form>
STF
<legend> Defines a caption for a fieldset element. Example:
<form>
  <fieldset>
    <legend>Personalia:</legend>
    Name: <input type="text" size="30" /><br />
    Email: <input type="text" size="30" /><br />
    Date of birth: <input type="text" size="10" />
  </fieldset>
</form>
STF
<li> Defines a list item. Example:
<ol>
  <li>Coffee</li>
  <li>Tea</li>
  <li>Milk</li>
</ol>

<ul>
  <li>Coffee</li>
  <li>Tea</li>
  <li>Milk</li>
</ul>
STF
<link /> Defines the relationship between a document and an external resource. Example:
<head>
<link rel="stylesheet" type="text/css" href="theme.css" />
</head>
STF
<map> Defines an image-map. Example:
<img src="planets.gif" width="145" height="126" alt="Planets" usemap="#planetmap" />

<map name="planetmap">
  <area shape="rect" coords="0,0,82,126" href="sun.htm" alt="Sun" />
  <area shape="circle" coords="90,58,3" href="mercur.htm" alt="Mercury" />
  <area shape="circle" coords="124,58,8" href="venus.htm" alt="Venus" />
</map>
STF
<menu> Deprecated. Defines a menu list. Example:
<menu>
  <li>html</li>
  <li>xhtml</li>
  <li>css</li>
</menu>
TF
<meta /> Defines metadata about an HTML document. Example:
<head>
<meta name="description" content="Free Web tutorials" />
<meta name="keywords" content="HTML,CSS,XML,JavaScript" />
<meta name="author" content="Hege Refsnes" />
<meta http-equiv="Content-Type" content="text/html;charset=ISO-8859-1" />
</head>
STF
<noframes> Defines an alternate content for users that do not support frames. Example of simple three framed page:
<html>

<frameset cols="25%,50%,25%">
  <frame src="frame_a.htm" />
  <frame src="frame_b.htm" />
  <frame src="frame_c.htm" />
  <noframes>
    Sorry, your browser does not handle frames!
  </noframes>
</frameset>

</html>
TF
<noscript> Defines an alternate content for users that do not support client-side scripts. Example:
<script type="text/javascript">
document.write("Hello World!")
</script>
<noscript>Your browser does not support JavaScript!</noscript>
STF
<object> Defines an embedded object. Example:
<object classid="clsid:F08DF954-8592-11D1-B16A-00C0F0283628" id="Slider1" width="100" height="50">
  <param name="BorderStyle" value="1" />
  <param name="MousePointer" value="0" />
  <param name="Enabled" value="1" />
  <param name="Min" value="0" />
  <param name="Max" value="10" />
</object>
STF
<ol> Defines an ordered list. Example:
<ol>
  <li>Coffee</li>
  <li>Tea</li>
  <li>Milk</li>
</ol>
STF
<optgroup> Defines a group of related options in a select list. Example:
<select>
  <optgroup label="Swedish Cars">
    <option value="volvo">Volvo</option>
    <option value="saab">Saab</option>
  </optgroup>
  <optgroup label="German Cars">
    <option value="mercedes">Mercedes</option>
    <option value="audi">Audi</option>
  </optgroup>
</select>
STF
<option> Defines an option in a select list. Example of drop down list with four options:
<select>
  <option>Volvo</option>
  <option>Saab</option>
  <option>Mercedes</option>
  <option>Audi</option>
</select>
STF
<p>
Defines a paragraph <p>This is a paragraph.</p>

<p align=left> Align text to the left
<p align=right> align text to the right
<p align=center> align text to the center
STF
<param /> Defines a parameter for an object. Example of an object to a HTML page:
<object classid="clsid:F08DF954-8592-11D1-B16A-00C0F0283628" id="Slider1" width="100" height="50">
  <param name="BorderStyle" value="1" />
  <param name="MousePointer" value="0" />
  <param name="Enabled" value="1" />
  <param name="Min" value="0" />
  <param name="Max" value="10" />
</object>
STF
<pre> Defines preformatted text. Example:
<pre>
Text in a pre element
is displayed in a fixed-width
font, and it preserves
both      spaces and
line breaks
</pre>
STF
<q> Defines a short quotation. Example:
<q>
Here is a short quotation here is a short quotation
</q>
STF
<s> Deprecated. Defines strikethrough text. Example:
<p>Version 2.0 is <s>not yet available!</s> now available!</p>

<p>Version 2.0 is <strike>not yet available!</strike> now available!</p>
TF
<samp> Defines sample computer code. Example:
<em>Emphasized text</em>
<strong>Strong text</strong>
<dfn>Definition term</dfn>
<code>Computer code text</code>
<samp>Sample computer code text</samp>
<kbd>Keyboard text</kbd>
<var>Variable</var>
<cite>Citation</cite>
STF
<script> Defines a client-side script. Example of insert JavaScript into HTML:
<script type="text/javascript">
document.write("Hello World!")
</script>
STF
<select> Defines a select list (drop-down list). Example:
<select>
  <option value="volvo">Volvo</option>
  <option value="saab">Saab</option>
  <option value="mercedes">Mercedes</option>
  <option value="audi">Audi</option>
</select>
STF
<small> Defines small text, Example:
<tt>Teletype text</tt>
<i>Italic text</i>
<b>Bold text</b>
<big>Big text</big>
<small>Small text</small>
STF
<span> Defines a section in a document. Example of text with a span element that can be styled with CSS:
<p>My mother has <span class="blue">light blue</span> eyes.</p>
STF
<strike> Deprecated. Defines strikethrough text. Example:
<p>Version 2.0 is <s>not yet available!</s> now available!</p>

<p>Version 2.0 is <strike>not yet available!</strike> now available!</p>
TF
<strong> Defines strong text. Formats words as bolded. Example:
<em>Emphasized text</em>
<strong>Strong text</strong>
<dfn>Definition term</dfn>
<code>Computer code text</code>
<samp>Sample computer code text</samp>
<kbd>Keyboard text</kbd>
<var>Variable</var>
<cite>Citation</cite>
STF
<style> Defines style information for a document. Example:
<html>
<head>
<style type="text/css">
h1 {color:red}
p {color:blue}
</style>
</head>

<body>
<h1>Header 1</h1>
<p>A paragraph.</p>
</body>
</html>
STF
<sub> Defines subscripted text. Example:
<p>This text contains <sub>subscript</sub> text.</p>

<p>This text contains <sup>superscript</sup> text.</p>
STF
<sup> Defines superscripted text.  Example:
<p>This text contains <sub>subscript</sub> text.</p>

<p>This text contains <sup>superscript</sup> text.</p>
STF
<table> Defines a table. Example of a simple HTML table containing two columns and two rows STF
<tbody> Groups the body content in a table. Example:
<table border="1">
  <thead>
    <tr>
      <th>Month</th>
      <th>Savings</th>
    </tr>
  </thead>
  <tfoot>
    <tr>
      <td>Sum</td>
      <td>$180</td>
    </tr>
  </tfoot>
  <tbody>
    <tr>
      <td>January</td>
      <td>$100</td>
    </tr>
    <tr>
      <td>February</td>
      <td>$80</td>
    </tr>
  </tbody>
</table>
STF
<td> Defines a cell in a table. Example of a simple HTML table containing two columns and two rows
<table border="1">
  <tr>
    <th>Month</th>
    <th>Savings</th>
  </tr>
  <tr>
    <td>January</td>
    <td>$100</td>
  </tr>
</table>
STF
<textarea> Defines a multi-line text input control. Example:
<textarea rows="2" cols="20">
At W3Schools you will find all the Web-building tutorials you need, from basic HTML to advanced XML, SQL, ASP, and PHP.
</textarea>
STF
<tfoot> Groups the footer content in a table. Example of
a HTML table with a thead, tfoot, and a tbody
element:
<table border="1">
  <thead>
    <tr>
      <th>Month</th>
      <th>Savings</th>
    </tr>
  </thead>
  <tfoot>
    <tr>
      <td>Sum</td>
      <td>$180</td>
    </tr>
  </tfoot>
  <tbody>
    <tr>
      <td>January</td>
      <td>$100</td>
    </tr>
    <tr>
      <td>February</td>
      <td>$80</td>
    </tr>
  </tbody>
</table>
STF
<th> Defines a header cell in a table. Example:
<table border="1">
  <tr>
    <th>Month</th>
    <th>Savings</th>
  </tr>
  <tr>
    <td>January</td>
    <td>$100</td>
  </tr>
</table>
STF
<thead> Groups the header content in a table. Example:
<table border="1">
  <thead>
    <tr>
      <th>Month</th>
      <th>Savings</th>
    </tr>
  </thead>
  <tfoot>
    <tr>
      <td>Sum</td>
      <td>$180</td>
    </tr>
  </tfoot>
  <tbody>
    <tr>
      <td>January</td>
      <td>$100</td>
    </tr>
    <tr>
      <td>February</td>
      <td>$80</td>
    </tr>
  </tbody>
</table>
STF
<title> Defines the title of a document. Example:
<html>
<head>
<title>Title of the document</title>
</head>

<body>
The content of the document......
</body>

</html>
STF
<tr> Defines a row in a table. Example:
<table border="1">
  <tr>
    <th>Month</th>
    <th>Savings</th>
  </tr>
  <tr>
    <td>January</td>
    <td>$100</td>
  </tr>
</table>
STF
<tt> Defines teletype text. Example of a format text in a document:
<tt>Teletype text</tt>
<i>Italic text</i>
<b>Bold text</b>
<big>Big text</big>
<small>Small text</small>
STF
<u> Deprecated. Defines underlined text. Example:
<p>Do not <u>underline</u> text if it is not a hyperlink!</p>
TF
<ul> Defines an unordered list. Example:
<ul>
  <li>Coffee</li>
  <li>Tea</li>
  <li>Milk</li>
</ul>
STF
<var> Defines a variable part of a text. Example:
<em>Emphasized text</em>
<strong>Strong text</strong>
<dfn>Definition term</dfn>
<code>Computer code text</code>
<samp>Sample computer code text</samp>
<kbd>Keyboard text</kbd>
<var>Variable</var>
<cite>Citation</cite>
STF
<xmp> Deprecated. Defines preformatted text  

Browser Support

The <address> tag is supported in all major browsers.


Differences Between HTML and XHTML

NONE


Tips and Notes

In all browsers, the content of the address element renders in italic. Most browsers will also add a line break before and after the address element.


Standard Attributes

DTD indicates in which HTML 4.01/XHTML 1.0 DTD the attribute is allowed. S=Strict, T=Transitional, and F=Frameset.

The <address> tag supports the following standard attributes:

Attribute Value Description DTD
class classname Specifies a classname for an element STF
dir rtl
ltr
Specifies the text direction for the content in an element STF
id id Specifies a unique id for an element STF
lang language_code Specifies a language code for the content in an element STF
style style_definition Specifies an inline style for an element STF
title text Specifies extra information about an element STF
xml:lang language_code Specifies a language code for the content in an element, in XHTML documents STF



Event Attributes

The <address> tag supports the following event attributes:

Attribute Value Description DTD
onclick script Script to be run on a mouse click STF
ondblclick script Script to be run on a mouse double-click STF
onmousedown script Script to be run when mouse button is pressed STF
onmousemove script Script to be run when mouse pointer moves STF
onmouseout script Script to be run when mouse pointer moves out of an element STF
onmouseover script Script to be run when mouse pointer moves over an element STF
onmouseup script Script to be run when mouse button is released STF
onkeydown script Script to be run when a key is pressed STF
onkeypress script Script to be run when a key is pressed and released STF
onkeyup script Script to be run when a key is released STF

Top