Web Page Design and Layout

Slides:



Advertisements
Similar presentations
Use Tables for Layout Control Day 7. You will learn to: Understand Tables Create a Simple Table Modify Your Tables Appearance Create Page Layouts with.
Advertisements

Chapter 3 – Web Design Tables & Page Layout
CREATED BY : VIRAL M.KORADIYA. Anchor elements are defined by the element. The element accepts several attributes, but either the Name or HREF attribute.
Multimedia and the World Wide Web HCI 201 Lecture Notes #5A.
Tutorial 4: Designing a Web Page with Tables
Web-based Application Development Lecture 9 February 7, 2006 Anita Raja.
Cos 125 Day 22. Agenda Assignment 6 Not corrected Waiting for tune-ins Assignment 7 is posted Assignment 7 Due April 2PM Left to do 1 Assignments.
XHTML1 Tables and Lists. XHTML2 Objectives In this chapter, you will: Create basic tables Structure tables Format tables Create lists.
Cos 125 Day 24. Agenda All students meeting 7 Pm Monday, April 19 UMS Strategic Plan Assignment #7 Posted Due April 20 Two (one?) more to go Quiz Four.
Creating a Web Page with Tables. Objectives Create a text table with preformatted text Create the basic structure of a graphical table Organize table.
XP Creating Web Pages with HTML Using Tables. XP Objectives Create a text table Create a table using the,, and tags Create table headers and captions.
Using HTML Tables.
The Power of Tables They aren't just for sitting stuff on anymore...
HTML Code. What we will cover Basic HTML Body Font Images Hyperlinks Tables Frames.
HTML. Goals How to use the Komodo editor HTML coding and testing Basic HTML tags List and Images Tables and Links At least 2 pages and navigation
XHTML1 Topics Work with the Frameset Document Type Definition (DTD) Create frames Use the target and base attributes Create nested frames Format frames.
HTML. Creating a Table Attributes: border: indicates the border type of the table Value: 0 (no border), 1, 2, etc. cols: indicates the number of columns.
What is a TABLE? The HTML table allows web designers to arrange & organize data -- text, images, hyperlinks, forms, form fields, other tables, etc. Tables.
INTRODUCTION TO WEB DEVELOPMENT AND HTML Lecture 06: Tables - Spring 2011.
Chapter 5 Working with Tables. Agenda Add a Table Assign a Table Border Adjust Cell Padding and Spacing Adjust Cell Width and Height Add Column Labels.
HTML. Goals How to use the Komodo editor HTML coding and testing – List and Images – Tables and Links – At least 2 pages and navigation –
1 The Structure of a Web Table beginning of the table structure first row of three in the table end of the table structure table cells You do not need.
CHAPTER 11 Tables. How Are Tables Used Data Display  Very tidy and very useful Better Text Alignment  Putting text in tables allows you to format indents.
Tutorial 4: Using CSS for Page Layout. 2 Objectives Session 4.1 Explore CSS layout Compare types of floating layouts Examine code for CSS layouts View.
Chapter 5 Creating Page Templates
XP 1 Tutorial 5 Using Frames in a Web Site. XP 2 Tutorial Objectives  Describe the uses of frames in a Web site  Lay out frames within a browser window.
1 3/7/05CS120 The Information Era Chapter 4 Basic Web Page Construction TOPICS: More on tables and images.
XP Dreamweaver 8.0 Tutorial 3 1 Adding Text and Formatting Text with CSS Styles.
10/4/2015Tables1 Spring, 2008 Modified by Linda Kenney 4/2/08.
CNIT 132 – Week 7 HTML - Tables. Tables on the World Wide Web A table can be displayed on a Web page either in a text or graphical format. A text table:
Copyright (c) 2004 Prentice-Hall. All rights reserved. 1 Committed to Shaping the Next Generation of IT Experts. Project 7: Working with Frames Kelly L.
Designing a Web Page with Tables. A text table: contains only text, evenly spaced on the Web page in rows and columns uses only standard word processing.
Introduction to Programming the WWW I CMSC Summer 2003 Lecture 5.
CSCE 102 – Chapter 6 (Web Design and Layout) CSCE General Applications Programming Benito Mendoza Benito Mendoza 1 By Benito Mendoza.
HTML (Hypertext Markup Language) – Class 3 Recap: HTML Special Characters (ex: ©). Including Images – using the tag. Lists – Ordered and Unordered.
TABLES 1. In this chapter you will learn that tables have many uses in HTML. Objectives: Upon completing this section, you should be able to: 1. Insert.
Chapter 5 Creating Page Templates. Principles of Web Design 2nd Ed. Chapter 5 2 Principles of Web Design Chapter 5 Objectives Understand table basics.
Week 9: HTML Tables and Frames HNDIT11062 – Web Development.
20-753: Fundamentals of Web Programming 1 Lecture 6: Advanced HTML Fundamentals of Web Programming Lecture 6: Advanced HTML.
LINKING WEBPAGES USING HTML HYPERLINKS. Hyperlinks are text strings or images on a webpage which when clicked on, links to another section in the same.
`. Lecture Overview HTML Body Elements Linking techniques HyperText references Linking images Linking to locations on a page Linking to a fragment on.
XHTML Introductory1 Frames Chapter 5. XHTML Introductory2 Objectives In this chapter, you will: Work with the Frameset Document Type Definition (DTD)
HTML Comprehensive Concepts and Techniques Second Edition Creating Frames on a Web Page.
Tutorial 4 Using CSS for Page Layout. Objectives Session 4.1 – Explore CSS layout – Compare types of floating layouts – Examine code for CSS layouts –
Designing a Web Page with Tables
Introduction to HTML.
CNIT 131 HTML5 - Tables.
CIIT-Human Computer Interaction-CSC456-Fall-2015-Mr
Webpage layout using CSS
Working with Tables: Module A: Table Basics
Tables and Frames.
LAB Work 02 MBA 61062: E-Commerce
Tutorial 8 Designing a Web Site with Frames
Chapter 5 Introduction to XHTML: Part 2
Programming the Web using XHTML and JavaScript
Chapter 5 - Introduction to XHTML: Part 2
The Internet 10/25/11 XHTML Tables
Cascading Style Sheets
Controlling Layout with Style Sheets
Using HTML Tables SWBAT: - create tables using HTML
Tutorial 8 Designing a Web Site with Frames
HTML Frames
Floating and Positioning
Introduction to HTML.
Lesson 5: HTML Tables.
Cascading Style Sheets
5.00 Apply procedures to organize content by using Dreamweaver. (22%)
Presentation transcript:

Web Page Design and Layout

Web Page Design In this unit, the students learn how to segment content in the browser window. Three different methods exist: style rules, tables, and frames. All can be used to create complex layouts like the often-used magazine-style configuration. Curiously, tables, are used by many web designers to organize information on the page because of their near universal support. The concept of frames is introduced which allows more than one document to be loaded and viewed in the browser window at the same time. Finally, we show how to open new document windows.

The Importance of Design User Interface! Entryway! First impressions! Diverse front-end platforms.

Some Basics Why are we building this site? Who is the target audience? What does the audience want? Some Good References: http://www.intranetjournal.com/articles/200103/intranet.html http://www.useit.com http://www.webpagesthatsuck.com

UI Principles User profiling. Metaphor/symbols. Feature exposure. Coherence. State visualization. Shortcuts. Focus. Grammar. Help. Safety. Context. Aesthetics. User testing. Humility. Talin, http://www.sylvantech.com/~talin/projects/ui_design.html

Key Implications Know your user! Provide familiarity and consistency. Guide your user (if they need it). Don’t slow your user down. Don’t turn your user away!

Some Technical Issues Bandwidth. Response time. Screen real estate. Multimedia, BHOs, Plug ins, …

Page Layout Options

Major Options CSS/styles. Tables. Frames.

Sample Page and General Layout This is My Wonderful Web Page Latest News: Sept. 27, 2004. Lately I have been spending most of my time getting ready for class and doing other work stuff. Fall break is coming up soon! Of course, before that I have to make and grade some tests. Yuk! Layout with Style Magazine-Style Layouts – magazine style layout has the title that spans the top of the page, image on left and three columns of text Start with determining the overall height and width of site. Layouts are nominally 600 pixels wide by 450 pixels high Sktech design on paper and figure the size and positions of various elements, think dimensions in exact pixels 5 elements/sections: title section (60X600); image section (design around image or edit to fit area); three columns (200 in length) Normal flow in a HTML document is the elements, tags, and text in a source document loading into a browser’s display in a top to bottom order. The position property allows you to specify the exact placement of an element but this is outside of the normal flow. So a mix of specified and not will not work well. If the text is normal flow then it is formatted and dispalyed as if the image with a position property is not there nt all. Specify the position property for all elements to make this work, using the <div> tag. Using a style definition to specify the absolute position of a web page element (an image, in this case): <style type="text/css"> img.eiffeltower {position:absolute; top:100; left:200} </style> </ head> <body> <img class=“eiffletower” src=“eiffel.gif” alt=“Eiffel Tower Picture” / > < / body> My resume Pictures Fun Stuff Work Stuff Links HPU Web Site HPU E-mail IS Department Microsoft IBM HP

Positioning Web Page Elements div.col1 {position:absolute; left:0; top:290; bottom:500; width:200} div.col2 {position:absolute; left:200; top:290; bottom:500; width:200} div.col3 {position:absolute; left:400; top:60; bottom:500; width:200} div.col1 {position:absolute; left:0; top:340; bottom:500; width:200; padding:5 10} Creating the magazine-style using the styles (<div> element). Use <div> tags to create the different divisions of the document Creating a Layout Using the <div> Element. Define the five elements using classes of the div element, specifying the absolute locations for each using the position property. Each of these divisions can be positioned on the page by using the position property, creating the column layout Graphics and titles can be positioned in a similar fashion The first three are an example of using a style definition to create three columns by specifying the absolute position of <div> elements: Last example is adding equal padding around the inside of a <div> element Adding 5 pixels of padding at the top and bottom of a <div> element and 10 pixels of padding on the left and right sides: (10 pixels worth, in this case): div.col1 {position:absolute; left:0; top:340; bottom:500; width:200; padding:10} Designing a layout takes some trail and error; Hint using the background color property makes it easy to see the area boundaries Make HTML document example page 149 – magazine style layout with <div> elements. Keep in mind; dispite <div> with the height property – the text will overflow its block; to control this add overflow:hidden to the element’s style definition (i.e. <div>)

CSS Box 1 Box 2 Box 3 Box 4 Box 5 Box 6

Table Table 2 Table 1 Table 3 Alternative to creating mag-style is using the HTML table – This is not the recommended approach. Consider creating ------------------------------------- define a table with two rows; 2nd row with two cells; 1st row use colspan to span across the bottom two cells ------------------------------------- | Make HTML document like on page 154 - top Getting rid of the white space between table cells: <table cellspacing="0">...</table> Setting the vertical alignment of a cell’s contents (top, middle, or bottom): <td valign="top"> Nesting a table inside the cell of another table (in this case the nested table has two rows with two cells in the top row and three in the bottom row): <td width="400"> <!--A cell of the outer table--> <table width="400"> <tr> <!--First row of the nested table--> <td>...</td> </tr> <tr> <!--Second row of the nested table--> </table> </td> Table 3

colspan and rowspan colspan rowspan

Frames Frameset 2 Frameset 1 Frameset 3 Alternative create magazine style with frames <frameset> </frameset> in place of the body tag. Creating and Using Frames Giving Body to the Frame: The <frame> Tag Frames are created with the <frame> tag. Frames allow different HTML source documents to be displayed in each region. Table of contents is common use of frames; TOC can display at all times in a frame while another diaplays the HTML doc the TOC links to. This is accomplished using the target attribute that says what frame to display a linked document in. But limit use to 3 or 4 frames per page. There must be one frame for each column or row designation in the frameset declaration. <frameset > has two attributes rows / cols by pixel or % or relative position. Look at page 511 for complete list of attributes for <frame />Make HTML document like 164. The src attribute in the frame tag specifies the source document for that frame. Some browsers don’t support because intro after standard HTML. <noframes> will display a message to users that frames are not support by their browser. The <noframes> tag should be used to display information to browsers that do not support frames Linking Between Frames A frame can be given a name using the “name” attribute of the frame tag The name is used as the target of a hyperlink to send the linked material to another frame – allowing the user to click in one frame and change the contents of another Getting Out of a Frameset Linking to external sites requires that you eliminate the frameset so the external site is not “framed” Use the special target “_top” to break out of a frame set Opening Multiple Windows With Internet Explorer, you can open a new window by setting the target to a name of your choosing However, with Navigator 4.x, the browser will display an “…unable to locate server…” error and after clearing the error, the page will be displayed. Frames, unlike tables and style rules, can be used to load different HTML documents into different segments of the browser window The Potential and Limitations of Frames Framed sites can be designed so that hyperlinks clicked in one frame causes the hyperlinked document to load into a different frame Frames are not supported by some older browsers Bad frame design is prolific because browsers do not render frames exactly the same way; check your design on other browsers and operating systems The Layout Document Using <frameset> The frameset document has a <frameset> tag instead of the <body> element XHTML compliance requires a special document type declaration – frameset Framesets can be created as either rows or columns The size can be specified as either a percentage or pixel count Nested framesets are supported for complex layouts 6.3 Creating and Using Frames Defining a frameset with rows (three, in this case): <frameset rows="25%,45%,30%"> ... </frameset> Defining a frameset with columns (two, in this case): <frameset cols="40%,60%"> ... </frameset> Defining a frameset using pixel measurements instead of window percentages (three columns, in this case, with the asterisk indicating that the middle column gets whatever’s left after the 230 pixels of the other columns are subtracted from the window’s width): <frameset cols="80,*,150"> ... </frameset> Defining a nested frameset (two columns with two and three rows, respectively, in this case): <frameset cols="50%,50%"> <frameset rows="50%,50%"> </frameset> <frameset rows="33%,33%,33%"> Loading documents into a basic frameset: <frameset cols="40%,60%"> <frame src="WelcomePage.htm" /> <frame src="ContactsList.htm" /> Loading documents into a nested frameset: <frameset rows="25%,75%"> <frame src="TableOfContents.htm" /> <frame src="Introduction.htm" /> <frame src="ListOfPictures.htm" /> Displaying a message to surfers who view a page without a frames-capable browser (the <noframes> element is placed inside a <frameset> element): <noframes>This Web page uses frames and requires the use of a frames-capable browser, such as Netscape Navigator 2.0 or above or Microsoft Internet Explorer 3.0 or above.</noframes> Giving identifying names to frames (for use with the target attribute in links—see next example; note that the name attribute is often used instead of the id attribute, but the name attribute is now deprecated): <frame id="leftframe" src="ListOfLinks.htm" /> <frame id="rightframe" src="IntroMessage.htm" /> Specifying that a linked document be displayed in a certain frame (rightframe in this case): <a href="Doc1.htm" target="rightframe">Click here to view document 1</a> Erasing a frameset and going back to a full-window display: <a href="DocumentToDisplay.html" target="_top"> Click here to erase the frames and see the document in the full window </a> 6.4 Opening Multiple Windows HTML document like page 166. Opening a new browser window (where you replace "windowname" with a name of your choice): <p><a href="DocumentToDisplay.html" target=“rightframe"> Click here to see the document displayed in a new window</a></p> Display in full window, set target attribute to :_top” <p><a href="DocumentToDisplay.html" target=“_top"> Click here to see the document displayed in a new window</a></p> Display link in another window <p><a href="DocumentToDisplay.html" target=“windowname"> Click here to see the document displayed in a new window</a></p> Frameset 3

My Recommendation Start with tables – wide support and easy. Plan to move to CSS and Box model. Avoid frames – work and limited support. Exercises 6:1 and 6:2