HTML basics and Web standards concepts. ‣ What are web standards? ‣ Why do we use them? ‣ What is HTML and how does it work? ‣ Anatomy of a web page ‣

Slides:



Advertisements
Similar presentations
XHTML Week Two Web Design. 2 What is XHTML? XHTML is the current standard for HTML Newest generation of HTML (post-HTML 4) but has many new features which.
Advertisements

Dr. Alexandra I. Cristea XHTML.
WeB application development
1 HTML Standards & Compliance. 2 Minimum Required HTML tags: (must go in this order!)
XHTML Basics.
1. Content – Collective term for all text, images, videos, etc. that you want to deliver to your audience. 2. Structure – How the content is placed on.
George Mason University
Copyright © 2004 ProsoftTraining, All Rights Reserved. Lesson 3: XHTML Coding © 2007 Prosoft Learning Corporation All rights reserved ITD 110 Web Page.
Basics of HTML What is HTML?  HTML or Hyper Text Markup Language is the standard markup language used to create Web pages.  HTML is.
XHTML 16-Apr-17.
17-Jun-15 XHTML 2 What is XHTML? XHTML stands for Extensible Hypertext Markup Language XHTML is aimed to replace HTML.
Unit 2, cont. September 14 HTML,Validating your pages, Publishing your site.
Tutorial 1 Developing a Basic Web Page
Creating a Well-Formed Valid Document. 2 Objectives Introducing XHTML Creating a Well-Formed Document Creating a Valid Document Creating an XHTML Document.
Chapter 1 Understanding the Web Design Environment
Chapter 2 Introduction to HTML5 Internet & World Wide Web How to Program, 5/e Copyright © Pearson, Inc All Rights Reserved.
© Ms. Masihi 1.  A web page is created using a language called, Hypertext Markup Language, better known as HTML Code.  HTML is a user friendly language.
Hypertext Markup Language (HTML) Created by Sarah Dooley & Amanda Foster Edited and presented by Caroline Hallam September 9, 2014.
WEB DESIGN SOME FOUNDATIONS. SO WHAT IS THIS INTERNET.
Chapter 1 Variables in the Web Design Environment
Structure Content Presentation Semantics.
Creating Web Pages with HTML
1 Networks and the Internet A network is a structure linking computers together for the purpose of sharing resources such as printers and files Users typically.
Structure Content Presentation Semantics.
Headings, Paragraphs, Formatting, Links, Head, CSS, Images
Website Development & Management Getting to Know HTML Better CIT Fall Instructor: John Seydel, Ph.D.
XP Tutorial 9New Perspectives on Creating Web Pages with HTML, XHTML, and XML 1 Working with XHTML Creating a Well-Formed Valid Document Tutorial 9.
ULI101 – XHTML Basics (Part II) What is Markup Language? XHTML vs. HTML General XHTML Rules Block Level XHTML Tags XHTML Validation.
HTML 101 MPM What is a website? A website is basically a collection of web pages stored on a particular computer (called a web server) and accessed.
 XHTML is aimed to replace HTML  XHTML is almost identical to HTML 4.01  XHTML is a stricter and cleaner version of HTML  XHTML is HTML defined as.
CS 299 – Web Programming and Design Introduction to HTML.
XHTML The Basics A brief history of HTML SGML (Standard Generalized Markup Language) Then came HTML Followed by the browser…and the great browser wars.
.  Entertain  Inform  Educate  Blogs  Sell  Date  Gamble  Religion.
Chapter 1 Understanding the Web Design Environment Principles of Web Design, 4 th Edition.
Week 1 Understanding the Web Design Environment. 1-2 HTML: Then and Now HTML is an application of the Standard Generalized Markup Language Intended to.
Essential Tags Web Design – Sec 3-3 Part or all of this lesson was adapted from the University of Washington’s “Web Design & Development I” Course materials.
Web page - A Web page is a simple text file that contains a set of HTML tags (code) that describe (to the browser) what should go on a web page. It may.
3 XHTML.
1 HTML XHTML. 2 Understand the Doctype tag Know the html tags which are now classed as depreciated Understand how Dreamweaver adds styles Add styles to.
Website Development & Management Creating Web Pages CIT Fall Instructor: John Seydel, Ph.D.
1 XHTML محمد احمدی نیا 2 Of 19 HTML vs XHTML  XHTML is a stricter and cleaner version of HTML.  by combining the strengths of HTML.
HTML. WHAT IS HTML HTML stands for Hyper Text Markup Language HTML is not a programming language, it is a markup language A markup language is a set of.
XHTML. Introduction to XHTML What Is XHTML? – XHTML stands for EXtensible HyperText Markup Language – XHTML is almost identical to HTML 4.01 – XHTML is.
Unit 2, cont. September 12 More HTML. Attributes Some tags are modifiable with attributes This changes the way a tag behaves Modifying a tag requires.
Lesson 4.
Copyright © Osmosys O S M O S Y SO S M O S Y S D e p l o y i n g E x p e r i e n c e & E x p e r t i s e™ HTML Training.
XHTML By Trevor Adams. Topics Covered XHTML eXtensible HyperText Mark-up Language The beginning – HTML Web Standards Concept and syntax Elements (tags)
ECA 228 Internet/Intranet Design I Intro to Markup.
Copyright (c) 2004 Prentice-Hall. All rights reserved. 1 Committed to Shaping the Next Generation of IT Experts. Creating XHTML Documents Essentials for.
CIS67 Foundations for Creating Web Pages Professor Al Fichera Rev. August 25, 2010—All HTML code brought to XHTML standards.
1 Web Application Programming Presented by: Mehwish Shafiq.
Lecture: Web Design Assis. Prof. Freshta Hanif Ehsan Faculty of Computer Science Kabul Polytechnic University Spring Semester
Review for exam 1 Midterm Closed Book. Review for Exam 1 Blackboard topic Review for exam 1 Sample Question Multiple Choice True / False Matching type.
Web Application Programming Presented by: Mehwish Shafiq.
Copyright © 2003 Pearson Education, Inc. Slide 1-1 Created by Cheryl M. Hughes The Web Wizard’s Guide to XHTML by Cheryl M. Hughes.
CS 330 Class 2: Programming Plan for Today Recap from last time More UNIX Begin HTML (material from Chapters 5-8) –Tags and attributes –Hyperlinks Features.
©SoftMoore ConsultingSlide 1 Introduction to HTML: Basic Document Structure.
Objective: To describe the evolution of the Internet and the Web. Explain the need for web standards. Describe universal design. Identify benefits of accessible.
Introduction to the World Wide Web & Internet CIS 101.
CSS IS A LANGUAGE DESIGNED TO TARGET HTML ELEMENTS AND NODES BY TYPE, CLASS, ID AND VALUE, AND CHANGE THEIR VALUES CSS – change how your HTML looks and.
Web Design – Week 2 Introduction to website basics Website basics: How the Web Works Client / server architecture Packet switching URL components.
Web Design Principles 5 th Edition Chapter 3 Writing HTML for the Modern Web.
Building a Web Page. A Brief History In 1989, Tim Berners-Lee invented the Web. To enable particle physics from around the world to organize and share.
XHTML. What Is XHTML? XHTML stands for EXtensible HyperText Markup Language XHTML is almost identical to HTML XHTML is stricter than HTML XHTML is HTML.
HTML5 – Heading, Paragraph
Web Programming– UFCFB Lecture 9
Unit A.
Web Programming– UFCFB Lecture 9
Lesson 2: HTML5 Coding.
Presentation transcript:

HTML basics and Web standards concepts

‣ What are web standards? ‣ Why do we use them? ‣ What is HTML and how does it work? ‣ Anatomy of a web page ‣ The different HTML versions What we’ll cover

What are open web standards?

‣ Technologies that the web is built on: ‣ Web infrastructure technologies (HTTP, TCP/IP, etc.) ‣ Technologies we build web sites with (HTML, CSS, JavaScript, SVG, etc.) What are open web technologies?

‣ No. ‣ Some technologies are closed/proprietary. ‣ They are created by only one company. ‣ And/or they are not interoperable with other open technologies. Are all technologies open?

‣ Are developed in cooperation by multiple companies. ‣ With standards bodies (Like W3C) curating them. ‣ They are interoperable with each other. ‣ They are not dependant on patents, and free to use by anyone. Open technologies

‣ The web should be open to anyone to use and develop. ‣ Not only those with the right political influence. ‣ Or those who can afford expensive software. Why are open technologies good?

‣ In real life standards are all around us. ‣ Traffic lights, common icons, screws, shoe sizes. ‣ They ensure things will just work. Standards?

‣ Web standards do the same thing for the Web. ‣ They are defined in big specification documents. ‣ Browser vendors are encouraged to implement them equally. ‣ So the same code will work across browsers. ‣ Today this is mostly the case. In the old days we used to have the browser wars. From standards to web standards

‣ The late 90s and early 00s were dark times. ‣ Netscape and IE fought to win market share by implementing features in incompatible ways. ‣ Terrible for both developers and users. The browser wars

‣ The late 90s and early 00s were dark times. ‣ Netscape and IE fought to win market share by implementing features in incompatible ways. ‣ Terrible for both developers and users. The browser wars

What is a web site made up of?

‣ Choosing a domain name and linking it to that web server. ‣ Putting several different files together. ‣ Uploading them to a web server using FTP. A web site is made by

‣ You buy one from a domain registration company, like GoDaddy or 123-Reg ‣ You find ‣ Choosing a domain name and linking it to that web server Choosing a domain name

‣ Hosting space is bought form a hosting company, like Rackspace or Media Temple ‣ It sometimes comes with the domain name ‣ Connect the hosting space to the domain name via nameservers Getting hosting space

‣ FTP is a web standard: File Transfer Protocol ‣ An FTP program is used to upload your web files onto your hosting space FTP

‣.html: Contains the content of our pages and defines its structure and purpose ‣.css: Contains styling information to define how the content should look ‣.js: Applies dynamic interactive behaviour to the content Types of file on the Web

‣.php,.net: server-side languages — these contain dynamic code that generates different client-side content depending on variables ‣ Images and video — media files that are used as part of the content ‣ Non-web files:.doc,.pdf and other non-web content that aren’t interpreted by the web browser Types of file on the Web

‣ Also known as static vs dynamic. ‣ HTML/CSS/JS are static — they’re downloaded as is, then rendered by the browser and displayed. ‣ PHP etc. are dynamic — they are rendered on the server, generating different client-side depending on what variables are fed to them. Client-side vs server-side

‣ index.html ‣ other pages (sometimes in folders) ‣ styles folder ‣ scripts folder ‣ folders for assets — fonts, images, video, etc. Creating a site folder

‣ index.html ‣ other pages (sometimes in folders) ‣ styles folder ‣ scripts folder ‣ folders for assets — fonts, images, video, etc. Creating a site folder

The anatomy of HTML

‣ What we structure our content in. ‣ It’s a tag-based language. ‣ You wrap your content in tags to give it meaning and structure. ‣ Let’s have a look. HTML is...

‣ : The opening tag of the element. ‣ : The closing tag of the element. ‣ Link to Amazon : The content of the element. We’re wrapping them in tags to make a link. Link to Amazon

‣ href=” : An attribute — attributes modify element behaviour. In this case, it defines that the link is going to point to amazon.co.uk ‣ href : The attribute name. ‣ : The attribute value. Link to Amazon

‣ Always put attribute values in quotes, even though you don’t really have to. Makes it easier to read. ‣ Always close elements that you open: This paragraph is not ok. ‣ Always nest elements correctly: This isn’t ok either Some simple rules

‣ Some elements don’t surround any content. For example: ‣ ‣ These are called “empty elements” or sometimes “self-closing elements” Not all elements have content!

‣ Block level elements start on a new line and stretch across the browser window. Examples:, ‣ Inline elements don’t start on a new line, and only stretch as far as the content they encapsulate. Examples:, Block and inline elements

‣ ‣ Note you can have multiple attributes. ‣ They should all have a space between them. ‣ The attribute name, equals sign, quotes and value shouldn’t have any spaces between them. More complex attribute example

‣ historically these defined the version of HTML the document is written in so it can be validated against a specific ruleset ‣ Let’s look at some examples DOCTYPES

‣ HTML 4.01 strict ‣ ‣ XHTML 1.0 transitional ‣ 1- transitional.dtd"> DOCTYPES

‣ But all they ever did was put browsers in “standards mode” versus “quirks mode” ‣ Because of this, you still need to include a doctype. ‣ But they were so long and unwieldy DOCTYPES

‣ HTML5 was therefore rewritten to include the shortest DOCTYPE possible that would put browsers into standards mode. ‣ DOCTYPES

‣ First you have the DOCTYPE. ‣ Then you have the element, which wraps all other content. ‣ Then you have the, which contains all the page’s meta data, data about the page, such as linked stylesheets and keywords. ‣ Then you have the, which is where all the page content goes. The structure of an HTML document

HTML versus XHTML

‣ Developers used to talk about whether they preferred XHTML or HTML. ‣ HTML is a specialised markup language designed for marking up documents. ‣ XHTML is a reformulation of HTML as an XML vocabulary HTML vs XHTML

‣...in principle because it has stricter rules than HTML, so enforced better quality markup. XHTML was a good idea...

‣ self closing tags include trailing slash:. attribute values always quoted. attributes can't be minimized: checked="checked". code should all be lower case. XHTML:

‣ self closing tags needn’t include trailing slash:. attribute values don’t always have to be quoted. attributes can be minimized: checked. code can be upper or lower case. HTML:

‣ Old versions of IE wouldn’t serve it properly.Proper XHTML refuses to display at all if it contains ANY errors: not great for the Web.XHTML 2.0 was not compatible with the existing Web. But XHTML never caught on

‣ Professional developers use a variety of different styles.Most use a mixture of HTML and XHTML rules.HTML5 doesn’t care whether you use XHTML or HTML rules. In reality...

Deprecated elements

‣...before CSS was popular and well- supported, we used to use HTML to do all our styling and layout.Some elements were abused (e.g. tables for layout)Some elements were presentational Back in the old days...

‣ These are no longer included in the HTML spec: ‣ for setting background colour. ‣ for setting fonts. ‣ for centering content. ‣ for striking through content. Deprecated examples

‣...some old deprecated elements to give them new semantic meaning. ‣ is now for small/fine print, not just to make text small. ‣ is for drawing attention to text without giving it extra meaning, not just for bolding text. HTML5 has repurposed...