Presentation is loading. Please wait.

Presentation is loading. Please wait.

HTML and XHTML Controlling the Display Of Web Content.

Similar presentations


Presentation on theme: "HTML and XHTML Controlling the Display Of Web Content."— Presentation transcript:

1 HTML and XHTML Controlling the Display Of Web Content

2 Links  The tag is used for making links, either internally or externally  Attribute href="location" where location can be a URL or a relative path or a name in the current document  Attribute name allows you to create label to a particular part of the document for local links

3 Images  You can link to an image file and have that file open in the browser  You use the image tag to embed an image into another document  where image is the location of the image file  jpg, gif and png formats supported

4 Tables  Use the tag to create a table  Use border, cellspacing, cellpadding to control looks  Use … and … to group rows together  … for each row  for each cell in the row  for column and row labels (bold)  colspan and rowspan allow you to make irregular tables

5 Sample Table …

6 Forms  is a block-level element in the body of your HTML page  A form element can contain text input boxes, buttons, checkboxes, pull-down menus and images  Your document can have multiple form elements  A special button called Submit is used to send the form data to the server

7 Form Attributes  action (required) - provides the URL of the application that needs to get the form data  A cgi program or a mailto URL  method (required) - POST or GET  Other tags  enctype - encoding format for the data  Accept-charset  target - to send results to another window  id, name, title  event

8 Form Elements  Use the tag to create controls  type="input-type" needed to specify which type of control  name attribute needed to identify the element  There are special tags for, and

9 Input types  checkbox - for on/off options  radio - to select from several choices  name must be the same for all buttons in group  text - one-line text entry, you can specify maximum length  password - similar to text but the typed characters are masked  provides multi-line text input

10 Input types  button - to trigger an immediate action, usually some Javascript code specified in the event attribute  reset - clears the form  submit - activates the form processing sequence  image - creates a clickable image which triggers submit action  coordinates of the mouse are transmitted with the rest of the form data  tag works like button but gives you more control

11 Input types  file - allows user to specify name of file to be uploaded  hidden - stores information that is transmitted but not seen by the user  - pull-down menus  elements define choices

12 Frames  Use frames to display multiple pages in a single window  Use the following DOCTYPE declaration <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd" > http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd"  Replace the element with a element  rows and cols attributes control subdivision  use a element to give source and attributes for each frame (no content)

13 Framesets  Each creates a grid  cols and rows control the number of boxes  use one element for each box  use another to nest another grid into a box

14 frames  Each needs a URL in the href attribute  links within the displayed pages can use the target attribute to cause the linked page to be displayed in a different frame

15 Sources  Web Design and Programming by Paul S. Wang and Sanda S. Katila  HTML The Definitive Guide by Chuck Musciano and Bill Kennedy  Wikipedia  http://en.wikipedia.org/wiki/HTML  W3C  http://www.w3.org/


Download ppt "HTML and XHTML Controlling the Display Of Web Content."

Similar presentations


Ads by Google