HTML Hyperlinks (Links)

Similar documents
Fall Semester 2016 (2016-1)

CSS CSS how to display to solve a problem External Style Sheets CSS files CSS Syntax

What is CSS? NAME: INSERT OPENING GRAPHIC HERE:

HTML Text Formatting. HTML Session 2 2

CSS how to display to solve a problem External Style Sheets CSS files

HTML, beyond the basics

Programmazione Web a.a. 2017/2018 HTML5

Chapter 1 Getting Started with HTML 5 1. Chapter 2 Introduction to New Elements in HTML 5 21

Scripting for Multimedia LECTURE 5: INTRODUCING CSS3

استاد: امیر عسگری چناقلو ترم دوم درس طراحی صفحات وب

Web Publishing with HTML

INFORMATICA GENERALE 2014/2015 LINGUAGGI DI MARKUP CSS

CS 350 Internet Applications I Name: Exam II (CSS) October 29, 2013

Final Exam Study Guide

Figure 1 Properties panel, HTML mode

With HTML you can create your own Web site. This tutorial teaches you everything about HTML.

Web Technology. Assignment 3. Notes: This assignment is individual assignment, every student should complete it by himself.

Overview. Part I: Portraying the Internet as a collection of online information systems HTML/XHTML & CSS

DAY 4. Coding External Style Sheets

HTML, CSS, JavaScript

Web Programming HTML CSS JavaScript Step by step Exercises Hans-Petter Halvorsen

CITS1231 Web Technologies. Introduction to Cascading Style Sheets

Skill Area 323: Design and Develop Website. Multimedia and Web Design (MWD)

CSS Quiz Result. 2) Where in an HTML document is the correct place to refer to an external style sheet?

Three Ways to Use CSS:

Web Designing HTML5 NOTES

introduction to XHTML

HTML, CSS. Kristóf Kovács, Róbert Pálovics, Ferenc Wettl Kristóf Kovács, Róbert Pálovics, Ferenc Wettl HTML, CSS / 28

Comm 244 Week 3. Navigation. Navigation. Websites need a formalized system of links to allow users to navigate the site

What is a web site? Web editors Introduction to HTML (Hyper Text Markup Language)

It is possible to create webpages without knowing anything about the HTML source behind the page.

INTRODUCTION TO WEB USING HTML What is HTML?

Session 4. Style Sheets (CSS) Reading & References. A reference containing tables of CSS properties

Cascading style sheets, HTML, DOM and Javascript

HTML & CSS November 19, 2014

Introduction to Computer Science (I1100) Internet. Chapter 7

CSS Scripting and Computer Environment - Lecture 09

HTML. Mohammed Alhessi M.Sc. Geomatics Engineering. Internet GIS Technologies كلية اآلداب - قسم الجغرافيا نظم المعلومات الجغرافية

Basic CSS Lecture 17

Cascading Style Sheet. Styles as Tag Attributes. Syntax. <h1>: what font type/size is used? STYLE = SELECTOR {RULES} Attributes such as bgcolor

CSS: The Basics CISC 282 September 20, 2014

Markup Language SGML: Standard Generalized Markup Language. HyperText Markup Language (HTML) extensible Markup Language (XML) TeX LaTeX

Using Dreamweaver CS6

Lesson 5 Introduction to Cascading Style Sheets

HTML Summary. All of the following are containers. Structure. Italics Bold. Line Break. Horizontal Rule. Non-break (hard) space.

In the early days of the Web, designers just had the original 91 HTML tags to work with.

Navigation. Websites need a formalized system of links to allow users to navigate the site

Chapter 2:- Introduction to XHTML. Compiled By:- Sanjay Patel Assistant Professor, SVBIT.

Review Question 1. Which tag is used to create a link to another page? 1. <p> 2. <li> 3. <a> 4. <em>

Deccansoft Software Services

Adobe Dreamweaver CS5/6: Learning the Tools

INTRODUCTION TO CSS. Mohammad Jawad Kadhim

Unit 5 Web Publishing Systems Page 1 of 13 Part 4 HTML Part 4

Introduction to using HTML to design webpages

<body bgcolor=" " fgcolor=" " link=" " vlink=" " alink=" "> These body attributes have now been deprecated, and should not be used in XHTML.

Assignments (4) Assessment as per Schedule (2)

Dreamweaver Basics Outline

recall: a Web page is a text document that contains additional formatting information in the HyperText Markup Language (HTML)

Basic Web Pages with XHTML (and a bit of CSS) CSE 190 M (Web Programming), Spring 2008 University of Washington Reading: Chapter 1, sections

Web Publishing Basics I

GRAPHIC WEB DESIGNER PROGRAM

Using Dreamweaver CC. 6 Styles in Websites. Exercise 1 Linked Styles vs Embedded Styles

CSC 121 Computers and Scientific Thinking

As we design and build out our HTML pages, there are some basics that we may follow for each page, site, and application.

Shane Gellerman 10/17/11 LIS488 Assignment 3

CS 350 COMPUTER/HUMAN INTERACTION. Lecture 6

Center for Faculty Development and Support Making Documents Accessible

Lab 4 CSS CISC1600, Spring 2012

Overview of the Adobe Dreamweaver CS5 workspace

HTML (Hypertext Mark-up language) Basic Coding

Objective % Select and utilize tools to design and develop websites.

Client Side Concepts Quiz Solution

Syllabus - July to Sept

CSS stands for Cascading Style Sheets Styles define how to display HTML elements

CREATING A WEBSITE USING CSS. Mrs. Procopio CTEC6 MYP1

Index. alt, 38, 57 class, 86, 88, 101, 107 href, 24, 51, 57 id, 86 88, 98 overview, 37. src, 37, 57. backend, WordPress, 146, 148

HTML and CSS COURSE SYLLABUS

Project 1: Creating a Web Site from Scratch. Skills and Tools: Use Expression Web tools to create a Web site

CSS - Cascading Style Sheets

Web Site Development with HTML/JavaScrip

MODULE 2 HTML 5 FUNDAMENTALS. HyperText. > Douglas Engelbart ( )

A HTML document has two sections 1) HEAD section and 2) BODY section A HTML file is saved with.html or.htm extension

Cascading Style Sheets (CSS) Part 1 of 3: Introduction and overview

E , Fall 2007 More with stylesheets

OU EDUCATE TRAINING MANUAL

CITS1231 Web Technologies. HTML Tables and Page Design Issues

Skill Area 323: Design and Develop Website. Multimedia and Web Design (MWD)

A Balanced Introduction to Computer Science, 3/E

Markup Language. Made up of elements Elements create a document tree

Comp-206 : Introduction to Software Systems Lecture 23. Alexandre Denault Computer Science McGill University Fall 2006

COPYRIGHTED MATERIAL. Contents. Chapter 1: Creating Structured Documents 1

Islamic University of Gaza Faculty of Engineering Department of Computer Engineering ECOM Advanced Internet Technology Lab.

Chapter 3 Web Design & HTML. Web Design Class Mrs. Johnson

Chapter 3 Style Sheets: CSS

Web Technologies - by G. Sreenivasulu Handout - 1 UNIT - I

The Benefits of CSS. Less work: Change look of the whole site with one edit

COSC 2206 Internet Tools. CSS Cascading Style Sheets

CSS.

Methods for configuring Cascading Style Sheets. Applying style to element name selectors. Style Rule Basics. CMPT 165: Cascading Style Sheets

Implementing a chat button on TECHNICAL PAPER

Transcription:

WEB DESIGN

HTML Hyperlinks (Links) The HTML <a> tag defines a hyperlink. A hyperlink (or link) is a word, group of words, or image that you can click on to jump to another document. When you move the cursor over a link in a Web page, the arrow will turn into a little hand. The most important attribute of the <a> element is the href attribute, which indicates the link s destination. By default, links will appear as follows in all browsers: An unvisited link is underlined and blue A visited link is underlined and purple An active link is underlined and red

HTML Link Syntax The HTML code for a link is simple. It looks like this: <a href="url">link text</a> The href attribute specifies the destination of a link.

Example <a href="http://www.iqbal.com/">visit IQbaL</a> which will display like this: Visit IQbaL Clicking on this hyperlink will send the user to IQbaL homepage. Tip: The "Link text" doesn't have to be text. It can be an image or any other HTML element.

HTML Links - The target Attribute The target attribute specifies where to open the linked document. The example below will open the linked document in a new browser window or a new tab: Example <a href="http://www.iqbal.com/" target="_blank">visit IQbaL</a>

HTML Links - The id Attribute The id attribute can be used to create a bookmark inside an HTML document. Tip: Bookmarks are not displayed in any special way. They are invisible to the reader. Example An anchor with an id inside an HTML document: <a id="tips">useful Tips Section</a> Create a link to the "Useful Tips Section" inside the same document: <a href="#tips">visit the Useful Tips Section</a> Or, create a link to the "Useful Tips Section" from another page: <a href="http://www.iqbal.com/html_links.htm#tips"> Visit the Useful Tips Section</a>

The HTML <head> Element The <head> element is a container for all the head elements. Elements inside <head> can include scripts, instruct the browser where to find style sheets, provide meta information, and more. The following tags can be added to the head section: <title>, <style>, <meta>, <link>, <script>, <noscript>, and <base>.

The HTML <title> Element The <title> tag defines the title of the document. The <title> element is required in all HTML/XHTML documents. The <title> element: defines a title in the browser toolbar provides a title for the page when it is added to favorites displays a title for the page in search-engine results

The HTML <title> Element A simplified HTML document: <!DOCTYPE html> <html> <head> <title>title of the document</title> </head> <body> The content of the document... </body> </html>

The HTML <base> Element The <base> tag specifies the base URL/target for all relative URLs in a page: <head> <base href="http://www.iqbal.com/images/" target="_blank"> </head>

The HTML <link> Element The <link> tag defines the relationship between a document and an external resource. The <link> tag is most used to link to style sheets: <head> <link rel="stylesheet" type="text/css" href="mystyle.css"> </head>

The HTML <style> Element The <style> tag is used to define style information for an HTML document. Inside the <style> element you specify how HTML elements should render in a browser: <head> <style type="text/css"> body {background-color:yellow} p {color:blue} </style> </head>

The HTML <meta> Element Metadata is data (information) about data. The <meta> tag provides metadata about the HTML document. Metadata will not be displayed on the page, but will be machine parsable. Meta elements are typically used to specify page description, keywords, author of the document, last modified, and other metadata. The metadata can be used by browsers (how to display content or reload page), search engines (keywords), or other web services. <meta> tags always goes inside the <head> element.

<meta> Tags - Examples of Use Define keywords for search engines: <meta name="keywords" content="html, CSS, XML, XHTML, JavaScript"> Define a description of your web page: <meta name="description" content="free Web tutorials on HTML and CSS"> Define the author of a page: <meta name="author" content="hege Refsnes"> Refresh document every 30 seconds: <meta http-equiv="refresh" content="30">

The HTML <script> Element The <script> tag is used to define a client-side script, such as a JavaScript. The <script> element will be explained in a later chapter.

HTML head Elements

HTML Styles - CSS CSS (Cascading Style Sheets) is used to style HTML elements.

Styling HTML with CSS CSS was introduced together with HTML 4, to provide a better way to style HTML elements. CSS can be added to HTML in the following ways: Inline - using the style attribute in HTML elements Internal - using the <style> element in the <head> section External - using an external CSS file The preferred way to add CSS to HTML, is to put CSS syntax in separate CSS files. However, in this HTML tutorial we will introduce you to CSS using the style attribute. This is done to simplify the examples. It also makes it easier for you to edit the code and try it yourself.

Inline Styles An inline style can be used if a unique style is to be applied to one single occurrence of an element. To use inline styles, use the style attribute in the relevant tag. The style attribute can contain any CSS property. The example below shows how to change the text color and the left margin of a paragraph: <p style="color:blue;margin-left:20px;">this is a paragraph.</p>

HTML Style Example - Background Color The background-color property defines the background color for an element: Example : <!DOCTYPE html> <html> <body style="background-color:yellow;"> <h2 style="background-color:red;">this is a heading</h2> <p style="background-color:green;">this is a paragraph.</p> </body> </html>

HTML Style Example - Background Color The results :

HTML Style Example - Font, Color and Size The font-family, color, and font-size properties defines the font, color, and size of the text in an element: Example : <!DOCTYPE html> <html> <body> <h1 style="font-family:verdana;">a heading</h1> <p style="font-family:arial;color:red;font-size:20px;">a paragraph.</p> </body> </html>

HTML Style Example - Text Alignment The text-align property specifies the horizontal alignment of text in an element: Example : <!DOCTYPE html> <html> <body> <h1 style="text-align:center;">center-aligned heading</h1> <p>this is a paragraph.</p> </body> </html>

Internal Style Sheet An internal style sheet can be used if one single document has a unique style. Internal styles are defined in the <head> section of an HTML page, by using the <style> tag, like this: <head> <style type="text/css"> body {background-color:yellow;} p {color:blue;} </style> </head>

External Style Sheet An external style sheet is ideal when the style is applied to many pages. With an external style sheet, you can change the look of an entire Web site by changing one file. Each page must link to the style sheet using the <link> tag. The <link> tag goes inside the <head> section: <head> <link rel="stylesheet" type="text/css" href="mystyle.css"> </head>

HTML Style Tags

Deprecated Tags and Attributes In HTML 4, several tags and attributes were used to style documents. These tags are not supported in newer versions of HTML. Avoid using the elements: <font>, <center>, and <strike>, and the attributes: color and bgcolor.

Try it yourself Practice more and more to get the best results.