DHTML & ALPHABET SOUP Sp.772 spring 2002. A combination Html 4.0 Javascript The document object model (DOM) -- accessing individual document objects Cascading.

Slides:



Advertisements
Similar presentations
© 2010 Delmar, Cengage Learning Chapter 9 Positioning Objects with AP Div Tags.
Advertisements

© Park University, 2006 Creating an Interactive Web Page with DHTML and JavaScript Park University.
Cascading Style Sheets (CSS). Cascading Style Sheets With the explosive growth of the World Wide Web, designers and programmers quickly explored and reached.
CSS Digital Media: Communication and design 2007.
Part 5 Introduction to CSS. CSS Display - Block and Inline Elements A block element is an element that takes up the full width available, and has a line.
Cascading Style Sheets. CSS stands for Cascading Style Sheets and is a simple styling language which allows attaching style to HTML elements. CSS is a.
Cascading Style Sheets By: Valerie Kuna. What are Cascading Style Sheets? Cascading Style Sheets (CSS) are a standard for specifying the presentation.
Web Development & Design Foundations with XHTML Chapter 7 Key Concepts.
CSS BASICS. CSS Rules Components of a CSS Rule  Selector: Part of the rule that targets an element to be styled  Declaration: Two or more parts: a.
CIS 1310 – HTML & CSS 6 Layout. CIS 1310 – HTML & CSS Learning Outcomes  Describe & Apply the CSS Box Model  Configure Float with CSS  Designate Positioning.
กระบวนวิชา CSS. What is CSS? CSS stands for Cascading Style Sheets Styles define how to display HTML elements Styles were added to HTML 4.0 to.
Chapter 6 © 2012 by Addison Wesley Longman, Inc Introduction Def: A dynamic HTML document is one whose tag attributes, tag contents, or element.
3.1 Cascading Style Sheets. Motto Fashions fade, style is eternal. —Yves Saint Laurent.
HIGHER COMPUTING CSS. WHAT IS CSS? CSS: Cascaded Style Sheets used to separate a web site’s content(information) from its style(how it looks).
TECH2018 Multimedia and the Internet More about CSS and Page Layouts.
Dreamweaver -- CSS. Dreamweaver -- MX New icons are added in MX Most of the features commonly used in web design, and are same as FrontPage. New feature.
_______________________________________________________________________________________________________________ Web Design in a Nutshell 2 nd Edition1.
Week 4.  Three ways to apply CSS: Inline CSS Internal style sheets ( header style information) External style sheets.
Tutorial 4 Creating Special Effects with CSS
SEG3210 DHTML Tutorial. DHTML DHTML is a combination of technologies used to create dynamic and interactive Web sites. –HTML - For creating text and image.
Tutorial 6 By Sam INE 1020 Introduction to Internet Engineering 1 DHTML & CSS Tutorial 6.
CSCI N341: Client-Side Web Programming Copyright ©2004  Department of Computer & Information Science Advanced DHTML.
ECA 225 Applied Interactive Programming1 ECA 225 Applied Online Programming DOM.
 HTML stands for Hyper Text Mark-up Language. The coding language used to create documents for the World Wide Web  HTML is composed of tags. HTML tags.
SEG3210 DHTML Tutorial. DHTML DHTML is a combination of technologies used to create dynamic and interactive Web sites. –HTML - For creating text and image.
HTML, Third Edition--Illustrated Introductory 1 HTML, Third Edition Illustrated Introductory Unit E Formatting with Cascading Style Sheets.
ITCS373: Internet Technology Week 3: Introduction to CSS Dr. Faisal Al-Qaed.
Just A Few More Fun Objectives 1 Having Some Fun With Java Script 2 Using Style Sheets.
Advanced DHTML.
CSS Font CSS font properties define the font family, boldness, size, and the style of a text. CSS Font Families Generic family Font familyDescription Serif.
Michigan.gov - Style Sheets (CSS) Adding Style And Layout To HTML.
Cascading Style Sheets Class 2, Lecture 2 Rachel A Ober
ALBERT WAVERING BOBBY SENG. Week 2: HTML + CSS  Quiz  Announcements/questions/etc  Some functional HTML elements.
Introduction to Programming the WWW I CMSC Winter 2003 Lecture 7.
COP 3813 Intro to Internet Computing Prof. Roy Levow Lecture 3.
CNIT 133 Interactive Web Pags – JavaScript and AJAX DHTML.
CS 3870/CS 5870 Web Protocols, Technologies and Applications.
Web sites Design: Cascading Style Sheet (CSS) (Cont’d) Dimensions and Position of Elements –Width and Height Space –Table Cell Padding –Left and Top Position.
Lesson 03 // Cascading Style Sheets. CSS Stands for Cascading Style Sheets. We’ll be using a combination of Html and CSS to create websites. CSS is a.
Chapter 8 © 2001 by Addison Wesley Longman, Inc. 1 Chapter 8 Sebesta: Programming the World Wide Web.
 2004 Prentice Hall, Inc. All rights reserved. Chapter 13 - Dynamic HTML: Object Model and Collections Outline 13.1 Introduction 13.2 Object Referencing.
A really fairly simple guide to: mobile browser-based application development (part 2, CSS) Chris Greenhalgh G54UBI / Chris Greenhalgh
DHTML. What is it? Dynamic HTML. Not a standard unlike HTML or Java It is a term applied by both Netscape and Microsoft to a collection of technologies.
Cascading Style Sheets
ECA 225 Applied Interactive Programming1 ECA 225 Applied Online Programming DHTML Example.
XHTML Formatting font with a style declaration. Formatting Font HTML uses the font tag to change size and family of font But… the font tag is being deprecated.
INTRODUCTORY Tutorial 5 Using CSS for Layout and Printing.
3.2 Cascading Style Sheets. 2 Positioning Elements Normally, elements are laid out on the page in the order that they are defined in the XHTML document.
Lecture 2: Cascading Style Sheets (CSS) Instructor: Dr. M. Anwar Hossain.
Cascading Style Sheets Primary readings Presentations Explain & review projects with class mates.
Web Development & Design Foundations with XHTML Chapter 6 Key Concepts.
Chapter 6 © 2014 by Pearson Education Introduction Def: A dynamic HTML document is one whose tag attributes, tag contents, or element style properties.
Dr. Ahmet Cengizhan Dirican BIL 374 Internet Technologies 6. Dynamic Documents With JavaScript.
Introduction to Programming the WWW I CMSC Summer 2003 Lecture 6.
Chapter 10 Dynamic HTML (DHTML) JavaScript, Third Edition.
JavaScript IV Robin Burke ECT 270. Outline Final project reminder Style review Manipulating style Special effect examples.
Chapter 6 Dynamic Documents with JavaScript. © 2006 Pearson Addison-Wesley. All rights reserved Introduction Def: A dynamic HTML document is.
JavaScript and Ajax (JavaScript Dynamic HTML (DHTML)) Week 7 Web site:
Internet & World Wide Web How to Program, 5/e Copyright © Pearson, Inc All Rights Reserved.
Chapter 6 © 2003 by Addison-Wesley, Inc Introduction - Dynamic HTML is not a new markup language - A dynamic HTML document is one whose tag attributes,
Cascading Styles Sheets Positioning HTML elements.
CSS Introductions. Objectives To take control of the appearance of a Web site by creating style sheets. To use a style sheet to give all the pages of.
6.1 Introduction 6.2 Element Positioning
Using DHTML to Enhance Web Pages
Cascading Style Sheets
DynamicHTML Cascading Style Sheet Internet Technology.
Working with Special Effects
DynamicHTML Cascading Style Sheet Internet Technology.
Part 1: Cascading Style Sheets
6.1 Introduction 6.2 Positioning Elements
Presentation transcript:

DHTML & ALPHABET SOUP Sp.772 spring 2002

A combination Html 4.0 Javascript The document object model (DOM) -- accessing individual document objects Cascading style sheets -- separation of form and content Netscape 6, IE 5.5/6

DOM Document.images[] accesses all the images in a document (we’ve seen it in billboard type image-displays) Suppose we want to access headings, paragraphs, and individual words simple paragraph In javascript: var para = document.getElementByID(“simple”)

getElementsby… Var headings = document.getElementsByTagName(“h1”); Var secondheading = headings[2]

CSS The element of style Para.style.color = “#00FF00”; Changes the paragraph to green Other properties: style.font-size style.font- family style.background-color, style.background-image

Rollover link color changes a {text-decoration: none; color: #0000FF; } Function turnOn(currentLink) { CurrentLink.style.color = “#990000”; CurrentLink.style.textDecoration = “underline”;}

Continued… Function turnOff(currentlink) { currentLink.style.color = “#0000FF”; currentLink.style.textDecoration = “none”;} <a href=“home.html” onMouseOver=“turnOn(this);” onMouseOut = “turnOff(this);”> home

..explained When the users’ mouse goes over a link the event handler passes it to turnOn, modifying the style of the current link Note that values for style elements are specified as strings (e.g. “underline”)

A dynamic CSS toolbar..hang on! Highlights cells of a table Html for a cell: <a href=“#” onMouseOver=“linkOn(this, ‘news’);” onMouseOut = “linkOff(this, ‘news’);”> News!

linkOn Function linkOn(currentLink, cell) { currentLink.style.color = “#990000”; currentLink.style.fontWeight = “bold”; currentLink.style.textDecoration = “underline”; Var CurrentCell = document.getElementById(cell); currentCell.style.backgroundColor=“#CCCCCC”; }

linkOff Function linkOn(currentLink, cell) { currentLink.style.color = “#FFFFFF”; currentLink.style.fontWeight = “normal”; currentLink.style.textDecoration = “none”; Var CurrentCell = document.getElementById(cell); currentCell.style.backgroundColor=“#666666”; }

The header a {font-family: Arial, Helvetica, sans-serif; font-size: 12px; color: #FFFFFF; text- decoration: none;}. toolbar { background-color: #666666;}

style classes.welcome { font-family….} …. Welcome to Bill’s World!

Layers A positionable container (like photoshop) x,y,z dimensions z dimension points out at the user

div attributes position: can be absolute or relative (to any containing elemnt) left: distance from left edge of document/containing element (eg 100px) top: distance from top..(in pixels, too) z-index: stacking order of display if layers are overlapping. higher numbers win. elements without a z-index lose

Tabbed Folders (a la Hotmail) visibility:visible visibility:hidden have some function keep track of the current tab and the moused-over newtab, change their visibilities appropriately

Browser Detection if (document.getElementById) {isDOM = true;} else if(parseInt(navigator.appVersion) >= 4) { if(navigator.appName == “Netscape”) {isNN4 = true;} else if (navigator.appName==“Microsoft Internet Explorer”) {isIE4= true;}

Drop Down Menu Example DHTML CSS Links

show/hideLayer function showLayer(layerid) { var layer=document.getElementByID(layerid); layer.style.visibility = “visible”;} function hideLayer(layerid) { var layer=document.getElementByID(layerid); layer.style.visibility = “hidden”;}

more info w3c.org/style w3c.org/dom

Exercise… drop linkys WEDNESDAY: SHIGERU MIYAGAWA GUEST LECTURES!!!!!!!!!!! WILL BE FUN. UROP OPPRTUNITIES ABOUND! REMINDER: May 15th FINAL PROJECTS DUE AT LEAST ONE MEMBER FROM EACH GROUP MUST GO TO PRESENT THAT NIGHT. 7:30pm