









Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!










To enter text on your pages - all you have to do is simply enter the text. If you do not specify any attributes for text it will use the default size, font etc. of the visitor's browser.
To specify the overall font for your page add the **** tag at the beginning of the **** section.
**
my page
Hello! This is my page.
All text looks the same
since I only specified a basefont.
**
The color attribute selects the desired color for your text. The face attribute selects the desired font.
The tag will change the font.
**
My Page
Hello! This is my page.
This local text looks different.
This text looks like the first line.
**
The color attribute selects the desired color for your text. The face attribute selects the desired font.
The tags used to produce links are the **** and . The **** tells where the link should start and the **** indicates where the link ends. The target of the link is added to the **** tag using the href=" http://www.whateverpage.com " setting
Click here to go to yahoo.
You simply:
Specify the target in the . Then add the text that should work as a link. Finally add an **** tag to indicate where the link ends.
These are the tags for text formats:
TEXT writes text as bold
TEXT writes text in italics
TEXT writes underlined text
TEXT lowers text and makes it smaller
TEXT lifts text and makes it smaller
TEXT guess yourself! (Note: Netscape only.)
TEXT strikes a line through the text
TEXT writes text as on a classic typewriter
TEXT writes text exactly as it is, including spaces.
TEXT usually makes text italic
TEXT usually makes text bold
These are the tags for changing the font size
TEXT increase the size by one
TEXT decrease the size by one
TEXT writes text in biggest heading
TEXT writes text in smallest heading
TEXT
writes text in smallest fontsize. (8 pt)
TEXT
writes text in biggest fontsize ( pt)
The and tags are special in that they can be repeated. If you want to increase the font size with a factor two, then you could do it like this:
bla bla bla whatever bla bla bla
This page shows how to make different kinds of bulleted lists. You have the following bullet options:
disc circle square
Look at these examples to see the detailed syntax.
Makes a bulleted list using the default bullet type:
text text text
Starts a bulleted list using discs as bullets:
This is one line This is another line And this is the final line
Starts a bulleted list using circles as bullets:
o This is one line o This is another line o And this is the final line
Starts a bulleted list using squares as bullets: This is one line This is another line And this is the final line
This page shows how to make different kinds of numbered lists. You have the following number options:
Plain numbers Capital Letters Small Letters Capital Roman Numbers Small Roman Numbers
Look at these examples to see the detailed syntax.
Makes a numbered list using the default number type:
**** Starts a numbered list, first # being 5.
**** Starts a numbered list, using capital letters.
A. This is one line B. This is another line C. And this is the final line
**** Starts a numbered list, using small letters. a. This is one line b. This is another line c. And this is the final line
**** Starts a numbered list, using capital
roman numbers. I. This is one line II. This is another line III. And this is the final line
**** Starts a numbered list, using small roman numbers.
i. This is one line ii. This is another line iii. And this is the final line
**** Starts a numbered list, using normal numbers.
An example of how type and start can be combined. VII. This is one line VIII. This is another line IX. And this is the final line
This section will show how to add images to your pages. The tag used to insert an image is called img.
You can change the size of an image using the width and height attributes.
If you want to add a background image instead of a plain color there are some considerations you should make before doing so:
Is the background image discrete enough to not take away the focus from what's written on it? Will the background image work with the text colors and link colors I set up for the page? Will the background image work with the other images I want to put on the page? How long will the page take to load my background image? Is it simply too big? Will the background image work when it is copied to fill the entire page? In all screen resolutions?
After answering these questions, if you still want to add the background image you will need to specify in the **** tag which image should be used for the background.
When you choose to use a background image for the page it is always a good idea to specify a background color as well. The reason is that until the background image is loaded, the background color will be shown.
The background image will scroll when the user scrolls down the page, unless you have set it to be fixed:
By adding the bgproperties="fixed" you force the browser to let the background be fixed even if the user is scrolling down the page.
Tables are used on websites for two major purposes:
The obvious purpose of arranging information in a table The less obvious - but more widely used - purpose of creating a page layout with the use of hidden tables.
The most important layout aspects that can be done with tables are:
Dividing the page into separate sections. An invisible table is excellent for this purpose. Creating menus. Typically with one color for the header and another for the links following in the next lines. Adding interactive form fields. Typically a gray area containing a search option. Creating fast loading headers for the page. A colored table with a text on it loads like a bullet compared to even a small banner. Easy alignment of images that have been cut into smaller pieces. A simple way to allow text to be written in two or more columns next to each other.
Tables are defined with the **** tag. To add rows to your table use the **** and **** tags. You can divide rows into columns with **** and **** tags.
** This is row one, left side. This is row one, right side. This is row two, left side. This is row two, right side. **
The following properties can be added to the tag:
PROPERTY DESCRIPTION ALIGN=
LEFT CENTER RIGHT
left align table center table right align table BACKGROUND=FILENA ME
image inserted behind the table
BGCOLOR=#RRGGBB background color BORDER=N border thickness BORDERCOLOR=#RRG
GBB
border color
border shadow
CELLPADDING=N distance between cell and content CELLSPACING=N space between cells NOWRAP protects against linebreaks, even though the
content might be wider than the browser window. FRAME= VOID,
ABOVE, BELOW, LHS,
RHS, HSIDES, VSIDES,
BOX
removes all outer borders shows border on top of table shows border on bottom of table shows border on left side of table shows border on right side of table shows border on both horizontal sides shows border on both vertical sides shows border on all sides of table VALIGN=
TOP BOTTOM
aligns content to top of cells aligns content to bottom of cells WIDTH= N,N N,N%
minimum width of table in pixels minimum width in percentage of window size
These settings can be added to both **** and **** tags
PROPERTY DESCRIPTION ALIGN= LEFT
RIGHT CENTER
aligns content to the left of cells aligns content to the right of cells aligns content to the center of the cells BACKGROUND=FILENAM E
sets a background image for the cells
BGCOLOR=#RRGGBB sets a background color for the cells BORDERCOLOR=#RRGGB
B
sets color for the border of cells
BORDERCOLORDARK=#R sets color for the border shadow of cells
One line text field Characters shown. Max characters allowed. Name of the field. Initial value in the field Alignment of the field. Tab order of the field.
The size option defines the width of the field. That is how many visible characters it can contain. The maxlength option defines the maximum length of the field. That is how many characters can be entered in the field. If you do not specify a maxlength, the visitor can easily enter more characters than are visible in the field at one time. The name setting adds an internal name to the field so the program that handles the form can identify the fields. The value setting defines what will appear in the box as the default value. The align setting defines how the field is aligned. Valid entries are: TOP, MIDDLE, BOTTOM, RIGHT, LEFT, TEXTTOP, BASELINE, ABSMIDDLE, ABSBOTTOM. The tabindex setting defines in which order the different fields should be activated when the visitor clicks the tab key.
Password fields are similar to text fields. The difference is that what is entered into a password field shows up as dots on the screen. This is, of course, to prevent others from reading the password on the screen.
**Enter Password : **
Hidden fields are similar to text fields, with one very important difference! The difference is that the hidden field does not show on the page. Therefore the visitor can't type anything into a hidden field, which leads to the purpose of the field: To submit information that is not entered by the visitor.
Below is a listing of valid settings for hidden fields:
Hidden field
Name of the field. Value of the field. The name setting adds an internal name to the field so the program that handles the form can identify the fields. The value setting defines what will be sent once the form is submitted.
** **
The hidden field does not show, but still, when the form is submitted the hidden field is sent with it.
Text areas are text fields that can span several lines. Unlike most other form fields, text areas are not defined with an **** tag. Instead you enter a **** tag where you want the area to end. Everything written between these tags will be presented in the text area box.
Below is a listing of valid settings for text areas:
Text area - several lines Rows in the field.
Columns in the field. Name of the field. Tab order of the field.
Turns off linebreaking Shows linebreaking, but sends text as entered. Inserts linebreaks when needed and even sends it. The cols and rows settings are straightforward and simple. They specify how many columns and rows you want in your text area. The name setting adds an internal name to the field so the program that handles the form can identify the fields. The tabindex setting defines in which order the different fields should be activated when the visitor clicks the tab key. The wrap options are the most tricky part of text areas. o If you turn wrap of the text is handled as one long sequence of text without linebreaks. o If you set it to virtual the text appears on your page as if it recognized linebreaks - but when the form is submitted the linebreaks are turned off. o If you set it to physical the text is submitted exactly as it appears on the screen - linebreaks included.
**This is outside the area
**
** Cheese
Water
Beer
Wine
**
Drop-down menus are probably the most flexible objects you can add to your forms. Depending on your settings, drop-down menus can serve the same purpose as radio buttons (one selection only) or check boxes (multiple selections allowed). The advantage of a drop-down menu, compared to radio buttons or check boxes, is that it takes up less space.
Below is a listing of valid settings for drop-down menus:
HTML EXPLANATION SELECT
NAME= SIZE= MULTIPLE=
Drop-down menu Name of the field. Visible items in list. Allows multiple choices if yes.
Individual items in the menu. Default select the item. Value to send if selected.
Drop-down menus combine **** and **
**
The **** tag defines the menu.
The name setting adds an internal name to the field so the program that handles the form can identify the fields. The size option defines how many items should be visible at a time. Default is one item. The multiple setting will allow for multiple selections if present.
The **
**
When a visitor clicks a submit button, the form is sent to the address specified in the action setting of the **** tag.
Below is a listing of valid settings for submit buttons:
HTML EXPLANATION SUBMIT NAME= VALUE= ALIGN= TABINDEX=
Submit button Name of the button. Text written on the button. Alignment of the button. Tab order of the button. The name setting adds an internal name to the button so the program that handles the form doesn't confuse the button with the other fields. The value setting defines what is written on the button. The align setting defines how the button is aligned. Valid entries are: TOP, MIDDLE, BOTTOM, RIGHT, LEFT, TEXTTOP, BASELINE, ABSMIDDLE, ABSBOTTOM. The tabindex setting defines in which order the different fields should be activated when the visitor clicks the tab key.
**
**
When a visitor clicks a reset button, the entries are reset to the default values.
Below is a listing of valid settings for reset buttons:
HTML EXPLANATION RESET
NAME= VALUE= ALIGN= TABINDEX=
Reset button Name of the button. Text written on the button. Alignment of the button. Tab order of the button. The name setting adds an internal name to the button so the program that handles the form doesn't confuse the button with the other fields. The value setting defines what is written on the button. The align setting defines how the button is aligned. Valid entries are: TOP, MIDDLE, BOTTOM, RIGHT, LEFT, TEXTTOP, BASELINE, ABSMIDDLE, ABSBOTTOM. The tabindex setting defines in which order the different fields should be activated when the visitor clicks the tab key.
**
**
Image buttons have the same effect as submit buttons. When a visitor clicks an image button the form is sent to the address specified in the action setting of the **** tag.
Below is a listing of valid settings for image buttons:
The general color of text links is specified in the tag, like in the example below:
link - standard link - to a page the visitor hasn't been to yet. (standard color is blue - #0000FF). vlink - visited link - to a page the visitor has been to before. (standard color is purple - #800080). alink - active link - the color of the link when the mouse is on it. (standard color is red - #FF0000).
There are two methods for doing this:
Placing font tags between the and the tag. This method will work on all browsers except MSIE 3.
Click here to go to yahoo.
Using a style setting in the tag. This method works on MSIE3 and newer browsers.
Click here to go to yahoo.
By default, links will open in the current window or frame. You need to add a target if you want the link to open in another window or frame than the link itself is placed in. To do this you simply add a target="" to the .
Predefined targets are:
_blank loads the page into a new browser window. _self loads the page into the current window. _parent loads the page into the frame that is superior to the frame the hyperlink is in. _top cancels all frames, and loads in full browser window.
http://www.echoecho.com/htmllinks04.htm