Web standards pragmatism Patrick H. Lauke / Web Developers Conference / 12 November 2008 FROM VALIDATION TO THE REAL WORLD.

Slides:



Advertisements
Similar presentations
HAML/SASS and tenplate building clean semantic sites for less.
Advertisements

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.
Cascading Style Sheets
Cascading Style Sheets
Copyright © Terry Felke-Morris WEB DEVELOPMENT & DESIGN FOUNDATIONS WITH HTML5 Chapter 6 Key Concepts 1 Copyright © Terry Felke-Morris.
Layout using CSS. Using multiple classes In the head:.important{font-style:italic;}.title{color:red;} In the body: Here's a type of paragraph that is.
Today CSS HTML A project.
Chapter 3 – Designing your web pages Dr. Stephanos Mavromoustakos.
Copyright © Terry Felke-Morris WEB DEVELOPMENT & DESIGN FOUNDATIONS WITH HTML5 Chapter 6 Key Concepts 1 Copyright © Terry Felke-Morris.
Very quick intro HTML and CSS. Sample html A Web Title.
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.
1 Web Developer & Design Foundations with XHTML Chapter 9 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.
Building a Website: Cascading Style Sheets (CSS) Fall 2013.
Web Pages and Style Sheets Bert Wachsmuth. HTML versus XHTML XHTML is a stricter version of HTML: HTML + stricter rules = XHTML. XHTML Rule violations:
กระบวนวิชา 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.
Web Design with Cascading Style Sheet Lan Vu. Overview Introduction to CSS Designing CSS Using Visual Studio to create CSS Using template for web design.
Intermediate Level Course. Text Format The text styles, bold, italics, underlining, superscript and subscript, can be easily added to selected text. Text.
XP 1 Working with Cascading Style Sheets Creating a Style for Online Scrapbooks Tutorial 7.
XHTML and CSS Overview. Hypertext Markup Language A set of markup tags and associated syntax rules Unlike a programming language, you cannot describe.
4.01 Cascading Style Sheets
CSS (Cascading Style Sheets): How the web is styled Create Rules that specify how the content of an HTML Element should appear. CSS controls how your web.
TUTORIAL 8: Enhancing a Web Site with Advanced CSS
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.
Web Development & Design Foundations with XHTML Chapter 6 Key Concepts.
Tutorial #3 Cascading Style Sheets. Review: Last Class Image sizing Pathnames Project Default Path Relative Path Absolute Path Blackboard Homework Submission.
Today’s objectives  Complete web page  Using xhtml & CSS  Adding CSS to documents Embed url(File);  CSS.
Basic Responsive Design Techniques. Let’s take a look at this basic layout. It has a header and two columns of text, in a box that is centered on the.
Web Design I Spring 2009 Kevin Cole Gallaudet University
CSS The Definitive Guide Chapter 8.  Allows one to define borders for  paragraphs  headings  divs  anchors  images  and more.
INTRODUCTION TO HTML5 Styling Text. Change the Font Size  You can use the font-size property to change the font size for a document’s text.  Instead.
IDs versus Classes Naming Your Tags for Maximum Functionality.
HTML 4 Foundation Level Course HyperText Markup Language Most common language used in creating Web documents. You can use HTML to create cross-platform.
 This presentation introduces the following: › 3 types of CSS › CSS syntax › CSS comments › CSS and color › The box model.
CSS My favourite ICT lesson By Federico Boschi Cascading Style Sheets.
Today’s objectives  Assignment 1  Padding, Margins, Borders  Fluid Layout page  Building accessible Table  Element size with padding and border 
Tutorial #3 Cascading Style Sheets. Tutorial #2 Review - Anchors Links to Site DMACC Internal Links Go to Top Mail To me Local.
 Word doc for you to download › Link at the beginning of class › 10 Questions › Answers to be added inline  Post to Sakai when completed › No resubmits.
Introduction to CSS. What is CSS?  Cascading Style Sheets  Used for styling HTML  Also important in javascript and jquery for selectors  External.
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.
CSS = Cascading Style Sheet CSS consists of rules to display, style and decorate HTML elements Why CSS ? – Separate decoration from HTML markup (Ex :,,…)
 Remember that HTML is just text  Need to point to pictures  Use the img tag  alt: › screen reader › REQUIRED for this class and to validate.
The Language of the Internet. HTML5 Hypertext Markup Language- Fifth iteration Used to create documents containing text, images, and hyperlinks Has Grammar.
Html Tables Basic Table Markup. How Tables are Used For Data Display Tables were originally designed to display and organize tabular data (charts, statistics,
XHTML and CSS. The Browser The browser is not print!
Professor Waterman Cascading Style Sheets (CSS) is a language that works with HTML documents to define the way content is presented. The presentation.
Daveandal.net Cascading Style Sheets 101 “How I learnt to love CSS and found my inner designer”
Introduction to HTML. HTML Introduction HTML – Hypertext Markup Language are the instructions that tell a browser how to lay out the information (text,
Use CSS to Implement a Reusable Design Selecting a Dreamweaver CSS Starter Layout is the easiest way to create a page with a CSS layout You can access.
XP Review 2 New Perspectives on JavaScript, Comprehensive1 Introducing Cascading Style Sheets Formatting Web Pages with CSS.
11/12/2015 Box Model Reed Crouch. 11/12/2015  HTML elements can be considered as boxes. In CSS, the term "box model" is used when referring to layout.
HTML Basics. HTML Coding HTML Hypertext markup language The code used to create web pages.
Microsoft Expression Web 3 – Illustrated Unit D: Structuring and Styling Text.
CONTROLLING Page layout
CIS67 Foundations for Creating Web Pages Professor Al Fichera Rev. September 22, 2010—All HTML code brought to XHTML standards. Reference for CIS127 and.
Group 9: Through examples, explain how to build a css navigation bar. Presented by: Daniel Ku, Matt Iannacci & Iphia Henry.
 Add one element at a time  If it doesn’t do what you want, › Delete it › DON’T just keep piling on more items.
Creating Image Based Rollovers with CSS Mike Takahashi Office of Instructional Development.
Chapter 4 and 5. Objectives Introduce markup: elements and attributes How browsers interpret HTML documents Basic structure of HTML document What do style.
What is CSS? A set of style rules that tell the web browser how to present a web page or document. – In earlier versions of HTML, style characteristics,
Scott Marino MSMIS Summer Session Web Site Design and Authoring Session 4 Scott Marino.
Creating and editing web pages Patrick H. Lauke / EDU Staff Development / 22 March 2007 for the University of Salford.
4.01 Cascading Style Sheets
CSS Layouts: Grouping Elements
Cascading Style Sheets (Layout)
Creating a Baseline Grid
Styles and the Box Model
Fixed Positioning.
Training & Development
4.01 Cascading Style Sheets
Presentation transcript:

Web standards pragmatism Patrick H. Lauke / Web Developers Conference / 12 November 2008 FROM VALIDATION TO THE REAL WORLD

Who am I? Web Editor for University of Salford Co-lead of Web Standards Project (WaSP) ATF Occasional author

What are web standards?

Web standard tenets Boil down to three things: Valid (published grammar) Separation of content and presentation Semantic markup/code

Visual aesthetics? “Beautiful sites” can be created with any technology... Table-based layouts Font tags Giant images etc Why bother with web standards/CSS?

Why web standards Some advantages: Lighter code Easier to maintain Easier to change look/feel Multiple output media Accessibility SEO

Web standards and aesthetics? “You can't make good looking sites with web standards...”

Traditional “old school” way Choice of markup purely down to their look is too big... I'll use instead, or just a to indent More space between paragraphs... add a few empty or just lots of

Traditional “old school” way...then sprinkle presentational markup on top Heading this is important.

Web standards elements Building a page by defining: What each piece of content is in HTML What it looks like in CSS

Web standards process Distinct tasks: Mark up content with most appropriate elements — convey meaning, not look Apply styling (override browser defaults)

Semantic / structural markup Heading this is important.

I know kung fu... common pitfalls

New technology, old habits...

Meaningless content Presentational: Heading Very important. Subheading

Meaningless content Semantic: Heading Very important. Subheading

Non-semantic class/id names I know CSS..red { color: red; } I know CSS.

Non-semantic class/id names? I know CSS..red { color: green; } I know CSS.

Semantic class/id names! Presentational:... CSS... Semantic:... CSS...

Classitis – the “labelmaker” approach.nav { text-decoration: none; }

Classitis – cured #nav a { text-decoration: none; } Be smart with your CSS Use semantic structure to your advantage

Tables? “I've just learnt web standards and removed all tables from my site...”

Tables (faked) Misguided zealots go too far

Tables! Not all tables are evil... Tabular content (think Excel spreadsheet) Best way to define relationship Accessibility

“Fluff” images

Error: no entry found

“Fluff” images via CSS If only decorative... Decorative = presentation Add images as non-repeating CSS backgrounds

Error: no entry found p.warning { padding: 10px; border: 1px #000 solid; background: url(warn.gif) no-repeat left top; }

“Fluff” images via CSS...but sometimes you have to stick with images WYSIWYG authors? One-off images don't warrant new CSS rules

Image replacement Images used for headings etc Branding “Fancy” font Graphical buttons

Image replacement Mark up text version (proper semantics) Hide this text Put an image in its place

Image replacement Wrap text in a span, apply background image Heading h1 { width: 350px; height: 75px; padding: 0; background: url(heading.gif) no-repeat left top; }

Image replacement Hide the span Heading h1 { width: 350px; height: 75px; padding: 0; background: url(heading.gif) no-repeat left top; } h1 span { display: block; position: absolute; top: 0; left: -999em; }

Image replacement issues Multiple (unskilled/WYSIWYG) authors? Backgrounds don't normally print Sometimes, a humble image will do...

Dogmatism and standards

“If your site doesn't validate, you've failed and nobody wants to even talk to you...”

Dogmatism and standards Validation is not an end in itself Quality Assurance of your code Some rules can be bent, others can be broken Depends on your particular situation

Attack of the pedants... “What's the most semantic way of marking this up?”

Most semantic? University home About the Uni......

Take-away advice...

Web standards are not just about validation Easy to use standards in an inappropriate way Tables are for tabular data Sometimes, you have to compromise

Thank you...