The document discusses various control flow statements in C programming such as decision control statements (if, if-else, switch-case), looping statements (for, while, do-while loops), break, continue, goto, and functions. It provides examples of using each statement type and explains their syntax and usage. Key aspects like scope of variables, parameter passing methods (call by value, call by reference), and storage classes (auto, static, extern) related to functions are also covered in the document.
Strings in Python can be created using single quotes, double quotes, or triple quotes. Strings are immutable and indexing allows accessing individual characters. Strings can be sliced to extract substrings. The + operator is used for concatenation and * operator repeats strings. The split method returns a list of substrings split by a delimiter and join method concatenates strings with a delimiter.
Operator overloading allows operators like + and << to be used with user-defined types like classes. It is done by defining corresponding operator functions like operator+() and operator<<(). This allows objects to be used with operators in a natural way while providing custom behavior for that type. The rules for overloading include maintaining precedence and associativity of operators. Common operators like +, -, *, /, <<, >>, ==, =, [] and () can be overloaded to allow user-defined types to work with them.
The tutorial will introduce you to Python Packages. This Python basic tutorial will help you understand creating a Python package. You will understand the example of a Python Package. After that, you will understand different ways to access Python Packages. Further, the demonstration will educate you on how to create Python Package.
Python lists allow storing heterogeneous data elements and are mutable. Lists use square brackets and store elements by index starting from 0. Common list operations include accessing elements, slicing, concatenation, replication, updating and deleting elements. Functions like min(), max() and len() operate on lists while methods such as append(), insert(), pop(), sort() modify lists.
Static Data Members and Member FunctionsMOHIT AGARWAL
Static data members and static member functions in C++ classes are shared by all objects of that class. Static data members are initialized to zero when the first object is created and shared across all instances, while static member functions can only access other static members and are called using the class name and scope resolution operator. The example program demonstrates a class with a static data member "count" that is incremented and accessed by multiple objects to assign increasing code values, and a static member function "showcount" that prints the shared count value.
This document discusses function overloading, inline functions, and friend functions in C++. It defines function overloading as having two or more functions with the same name but different parameters. Inline functions have their body inserted at the call site instead of transferring control. Friend functions are non-member functions that have access to private members of a class. Examples are provided for each concept. The advantages of inline functions are reduced code size and faster execution, while disadvantages include increased file size and memory usage.
Este documento presenta una serie de ejercicios resueltos de programación en JavaScript utilizando ECMAScript 6. Incluye ejemplos de uso de clases, objetos, arrays, jQuery y JSON. Explica conceptos como objetos, patrones de diseño y métodos para crear y manipular elementos en la pantalla.
Pointers in C allow programs to store and manipulate memory addresses. The document explains that pointers store the address of another variable in memory and use dereferencing operators like * to access the value at that address. It demonstrates how to declare and assign pointers, pass pointers to functions, and use pointer arithmetic to traverse arrays. Key concepts covered include address-of & and dereference * operators, double pointers, and how modifying a pointer or value it points to changes the referenced memory location.
This document provides an overview of data types in Python. It discusses the main data types including numeric, boolean, sequence, set and mapping types. Numeric types include int, float, long and complex. Sequence types include string, bytes, byte array, list and tuple. Sets are unordered collections that can contain different data types. Dictionaries are unordered collections of key-value pairs. The document also distinguishes between mutable objects like lists and dictionaries whose values can change, and immutable objects like integers, floats and tuples whose values cannot change.
the slide about Exception handling in java and the file and io handling in java .inbuilt java packages in for java exception.for beginner in programming
The document describes various HTML tags for formatting text and displaying code. It defines tags for headings, paragraphs, and other basic text elements. It also covers tags for character formatting like bold, italics, and font styling. Finally, it outlines tags for displaying computer code and preformatted text, including <pre>, <code>, <tt>, <kbd>, <var>, <samp>, and <dfn>.
Problem Solving Aspect of Swapping Two Integers using a Temporary VariableSaravana Priya
This document describes an algorithm for exchanging the values of two variables. It involves:
1) Saving the original value of the first variable (a) in a temporary variable (t)
2) Assigning the value of the second variable (b) to the first variable (a)
3) Assigning the value stored in the temporary variable (t), which contains the original value of the first variable, to the second variable (b)
This exchanges the values stored in the two variables.
This document discusses functions in Python. It defines a function as a block of reusable code that has a name. The function header includes the name, parameters in parentheses, and return type. The function body contains the code within curly braces. Functions are called by their name and parameters are passed within parentheses. Examples are provided of defining, calling, and returning values from functions in Python.
Functions are blocks of reusable code that perform specific tasks. There are three types of functions in Python: built-in functions, anonymous lambda functions, and user-defined functions. Functions help organize code by breaking programs into smaller, modular chunks. They reduce code duplication, decompose complex problems, improve clarity, and allow code reuse. Functions can take arguments and return values. Built-in functions are pre-defined to perform operations and return results when given the required arguments.
This document discusses various C++ concepts including tokens, keywords, identifiers, constants, data types, user-defined data types like struct, union, enum, and class. It also covers derived data types like arrays, functions, and pointers. It provides examples and programs to demonstrate struct, union, enum, functions, pointers, and references. The document is a set of lecture notes that serves as an introduction to fundamental C++ programming concepts.
Templates allow functions and classes to operate on generic types in C++. There are two types of templates: class templates and function templates. Function templates are functions that can operate on generic types, allowing code to be reused for multiple types without rewriting. Template parameters allow types to be passed to templates, similar to how regular parameters pass values. When a class, function or static member is generated from a template, it is called template instantiation.
Constants Variables Datatypes by Mrs. Sowmya JyothiSowmyaJyothi3
C provides various data types to store different types of data. The main data types are integer, float, double, and char. Variables are used to store and manipulate data in a program. Variables must be declared before use, specifying the data type. Constants are fixed values that don't change, and can be numeric, character, or string values. Symbolic constants can be defined to represent constant values used throughout a program. Input and output of data can be done using functions like scanf and printf.
This document discusses data members and member functions in C++ classes. It defines data members as variables declared inside a class that can be of any type. Member functions are functions declared inside a class that can access and perform operations on the class's data members. The document outlines how data members and member functions can be defined with public, private, or protected visibility and how they can be accessed from within and outside the class. It also provides syntax examples for defining member functions both inside and outside the class definition.
Listas en Python permiten almacenar colecciones de elementos de diferentes tipos. Son mutables y dinámicas, lo que significa que se pueden modificar después de su creación y no es necesario especificar su tamaño de antemano. Se definen con corchetes y se pueden acceder y modificar sus elementos por posición. Se pueden recorrer con bucles for y realizar operaciones como agregar, eliminar e insertar elementos.
The document discusses files in Python. It describes that files allow storing data permanently on disk that can be accessed by Python programs. There are two main types of files - text files, which store data as characters, and binary files, which store data in the same format as memory. The document outlines various methods for opening, reading, writing, and closing files in Python. It also discusses file paths and different file access modes.
JavaScript is the programming language of the web. It can dynamically manipulate HTML content by changing element properties like innerHTML. Functions allow JavaScript code to run in response to events like button clicks or timeouts. JavaScript uses objects and prototypes to define reusable behaviors and properties for objects. It is an important language for web developers to learn alongside HTML and CSS.
Programming Fundamentals Arrays and Strings imtiazalijoono
This document provides an overview of arrays and strings in C programming. It discusses initializing and declaring arrays of different types, including multidimensional arrays. It also covers passing arrays as arguments to functions. For strings, it explains that strings are arrays of characters that are null-terminated. It provides examples of declaring and initializing string variables, and using string input/output functions like scanf() and printf().
Functions allow programmers to organize code into reusable blocks. A function is defined using the def keyword and can accept parameters. The body of a function contains a set of statements that run when the function is called. Functions can return values and allow code to be reused, reducing errors and improving readability. Parameters allow information to be passed into functions, while return values allow functions to provide results.
The document discusses dynamic memory allocation in C. It describes the four main functions for dynamic allocation - malloc(), calloc(), free(), and realloc(). malloc() allocates a block of memory of a specified size and returns a pointer. calloc() allocates multiple blocks of memory and initializes them to zero. free() releases previously allocated memory. realloc() changes the size of previously allocated memory. The document provides examples of using each function.
This document discusses polymorphism in C++. It defines polymorphism as the ability for functions or operators to have different meanings depending on the context. It describes different types of polymorphism including static and dynamic polymorphism. It then provides examples of method overloading, operator overloading, and virtual functions to illustrate polymorphism concepts in C++.
The document provides information on HTML (Hypertext Markup Language). It discusses that HTML is used to create web pages and applications, and is the most widely used language on the web. It also describes the basic structure of an HTML document and some common HTML tags like <html>, <head>, <body>, <p>, and <h1>.
This document discusses function overloading, inline functions, and friend functions in C++. It defines function overloading as having two or more functions with the same name but different parameters. Inline functions have their body inserted at the call site instead of transferring control. Friend functions are non-member functions that have access to private members of a class. Examples are provided for each concept. The advantages of inline functions are reduced code size and faster execution, while disadvantages include increased file size and memory usage.
Este documento presenta una serie de ejercicios resueltos de programación en JavaScript utilizando ECMAScript 6. Incluye ejemplos de uso de clases, objetos, arrays, jQuery y JSON. Explica conceptos como objetos, patrones de diseño y métodos para crear y manipular elementos en la pantalla.
Pointers in C allow programs to store and manipulate memory addresses. The document explains that pointers store the address of another variable in memory and use dereferencing operators like * to access the value at that address. It demonstrates how to declare and assign pointers, pass pointers to functions, and use pointer arithmetic to traverse arrays. Key concepts covered include address-of & and dereference * operators, double pointers, and how modifying a pointer or value it points to changes the referenced memory location.
This document provides an overview of data types in Python. It discusses the main data types including numeric, boolean, sequence, set and mapping types. Numeric types include int, float, long and complex. Sequence types include string, bytes, byte array, list and tuple. Sets are unordered collections that can contain different data types. Dictionaries are unordered collections of key-value pairs. The document also distinguishes between mutable objects like lists and dictionaries whose values can change, and immutable objects like integers, floats and tuples whose values cannot change.
the slide about Exception handling in java and the file and io handling in java .inbuilt java packages in for java exception.for beginner in programming
The document describes various HTML tags for formatting text and displaying code. It defines tags for headings, paragraphs, and other basic text elements. It also covers tags for character formatting like bold, italics, and font styling. Finally, it outlines tags for displaying computer code and preformatted text, including <pre>, <code>, <tt>, <kbd>, <var>, <samp>, and <dfn>.
Problem Solving Aspect of Swapping Two Integers using a Temporary VariableSaravana Priya
This document describes an algorithm for exchanging the values of two variables. It involves:
1) Saving the original value of the first variable (a) in a temporary variable (t)
2) Assigning the value of the second variable (b) to the first variable (a)
3) Assigning the value stored in the temporary variable (t), which contains the original value of the first variable, to the second variable (b)
This exchanges the values stored in the two variables.
This document discusses functions in Python. It defines a function as a block of reusable code that has a name. The function header includes the name, parameters in parentheses, and return type. The function body contains the code within curly braces. Functions are called by their name and parameters are passed within parentheses. Examples are provided of defining, calling, and returning values from functions in Python.
Functions are blocks of reusable code that perform specific tasks. There are three types of functions in Python: built-in functions, anonymous lambda functions, and user-defined functions. Functions help organize code by breaking programs into smaller, modular chunks. They reduce code duplication, decompose complex problems, improve clarity, and allow code reuse. Functions can take arguments and return values. Built-in functions are pre-defined to perform operations and return results when given the required arguments.
This document discusses various C++ concepts including tokens, keywords, identifiers, constants, data types, user-defined data types like struct, union, enum, and class. It also covers derived data types like arrays, functions, and pointers. It provides examples and programs to demonstrate struct, union, enum, functions, pointers, and references. The document is a set of lecture notes that serves as an introduction to fundamental C++ programming concepts.
Templates allow functions and classes to operate on generic types in C++. There are two types of templates: class templates and function templates. Function templates are functions that can operate on generic types, allowing code to be reused for multiple types without rewriting. Template parameters allow types to be passed to templates, similar to how regular parameters pass values. When a class, function or static member is generated from a template, it is called template instantiation.
Constants Variables Datatypes by Mrs. Sowmya JyothiSowmyaJyothi3
C provides various data types to store different types of data. The main data types are integer, float, double, and char. Variables are used to store and manipulate data in a program. Variables must be declared before use, specifying the data type. Constants are fixed values that don't change, and can be numeric, character, or string values. Symbolic constants can be defined to represent constant values used throughout a program. Input and output of data can be done using functions like scanf and printf.
This document discusses data members and member functions in C++ classes. It defines data members as variables declared inside a class that can be of any type. Member functions are functions declared inside a class that can access and perform operations on the class's data members. The document outlines how data members and member functions can be defined with public, private, or protected visibility and how they can be accessed from within and outside the class. It also provides syntax examples for defining member functions both inside and outside the class definition.
Listas en Python permiten almacenar colecciones de elementos de diferentes tipos. Son mutables y dinámicas, lo que significa que se pueden modificar después de su creación y no es necesario especificar su tamaño de antemano. Se definen con corchetes y se pueden acceder y modificar sus elementos por posición. Se pueden recorrer con bucles for y realizar operaciones como agregar, eliminar e insertar elementos.
The document discusses files in Python. It describes that files allow storing data permanently on disk that can be accessed by Python programs. There are two main types of files - text files, which store data as characters, and binary files, which store data in the same format as memory. The document outlines various methods for opening, reading, writing, and closing files in Python. It also discusses file paths and different file access modes.
JavaScript is the programming language of the web. It can dynamically manipulate HTML content by changing element properties like innerHTML. Functions allow JavaScript code to run in response to events like button clicks or timeouts. JavaScript uses objects and prototypes to define reusable behaviors and properties for objects. It is an important language for web developers to learn alongside HTML and CSS.
Programming Fundamentals Arrays and Strings imtiazalijoono
This document provides an overview of arrays and strings in C programming. It discusses initializing and declaring arrays of different types, including multidimensional arrays. It also covers passing arrays as arguments to functions. For strings, it explains that strings are arrays of characters that are null-terminated. It provides examples of declaring and initializing string variables, and using string input/output functions like scanf() and printf().
Functions allow programmers to organize code into reusable blocks. A function is defined using the def keyword and can accept parameters. The body of a function contains a set of statements that run when the function is called. Functions can return values and allow code to be reused, reducing errors and improving readability. Parameters allow information to be passed into functions, while return values allow functions to provide results.
The document discusses dynamic memory allocation in C. It describes the four main functions for dynamic allocation - malloc(), calloc(), free(), and realloc(). malloc() allocates a block of memory of a specified size and returns a pointer. calloc() allocates multiple blocks of memory and initializes them to zero. free() releases previously allocated memory. realloc() changes the size of previously allocated memory. The document provides examples of using each function.
This document discusses polymorphism in C++. It defines polymorphism as the ability for functions or operators to have different meanings depending on the context. It describes different types of polymorphism including static and dynamic polymorphism. It then provides examples of method overloading, operator overloading, and virtual functions to illustrate polymorphism concepts in C++.
The document provides information on HTML (Hypertext Markup Language). It discusses that HTML is used to create web pages and applications, and is the most widely used language on the web. It also describes the basic structure of an HTML document and some common HTML tags like <html>, <head>, <body>, <p>, and <h1>.
This document provides an introduction to HTML basics. It covers using HTML tags to structure a web page with headings, paragraphs, and other text elements. It explains how to add images, tables, colors and hyperlinks to an HTML page. The objectives are to learn how to author an HTML file using a text editor, apply basic tags, create hyperlinks and images, use tables, and style colors. It provides examples of HTML code and tags to get started building simple web pages.
This document provides an introduction to HTML basics. It covers using HTML tags to structure a web page with headings, paragraphs, and other text elements. It explains how to add images, tables, colors and hyperlinks to an HTML page. The document also discusses HTML tags, entities, fonts and backgrounds. It includes examples of basic HTML code and encourages the reader to practice writing HTML by opening a text editor and following along.
This document provides an introduction to HTML basics, including:
- The objectives of learning HTML tags to format text, add images, tables, colors and hyperlinks.
- Instructions on using a basic text editor to author an HTML file and view it in a browser.
- Examples of common HTML tags for headings, paragraphs, bold text, and line breaks.
- Descriptions of HTML elements, attributes, and how tags are used to structure and style content.
HTML Basics
Welcome to HTML Basics. This workshop leads you through the basics of Hyper Text Markup Language (HTML). HTML is the building block for web pages. You will learn to use HTML to author an HTML page to display in a web browser.
This document provides an introduction to HTML basics, including:
- The objectives of learning HTML tags to format text, add images, tables, colors and hyperlinks.
- Instructions on using a basic text editor to author an HTML file and view it in a browser.
- Examples of common HTML tags for headings, paragraphs, bold text, and line breaks.
- Descriptions of HTML elements, attributes, and how tags are used to structure and style content.
This document provides an introduction to HTML basics. It covers using HTML tags to structure a web page with headings, paragraphs, and other text elements. It explains how to add images, tables, colors and hyperlinks to an HTML page. The document also discusses HTML tags, elements, attributes and entities. It encourages using logical tags over physical tags and style sheets for formatting. It includes examples and instructions for creating a basic HTML page using a text editor and viewing it in a browser.
This document provides an introduction to HTML basics, including:
- The objectives of learning HTML tags to format text, add images, tables, colors and hyperlinks.
- Instructions on using a basic text editor to author an HTML file and view it in a browser.
- Examples of common HTML tags for headings, paragraphs, bold text, and line breaks.
HTML Basics
Welcome to HTML Basics. This workshop leads you through the basics of Hyper Text Markup Language (HTML). HTML is the building block for web pages. You will learn to use HTML to author an HTML page to display in a web browser.
This document provides an introduction to HTML basics, including:
- The objectives of learning HTML tags to format text, add images, tables, colors and hyperlinks.
- Instructions on using a basic text editor and saving files with the .html extension to author HTML documents.
- Examples of basic HTML tags for headings, paragraphs, bold text, and line breaks.
This document provides an introduction to HTML basics, including:
- HTML is used to author web pages and is made up of tags enclosed in angle brackets.
- The objectives are to use a text editor to author HTML, add basic tags, hyperlinks, images and tables.
- Notepad is recommended for Windows and TextEdit for Mac to author HTML files.
This document provides an introduction to HTML, including how to create basic HTML documents and use common HTML tags. It explains that HTML documents have a structure with <html>, <head>, and <body> tags. The <head> contains the <title> while the <body> holds visible content. It also describes important HTML attributes like id, title, class, and style that can be used on most tags. Meta tags are discussed for adding metadata to pages.
This document provides an introduction to HTML, including how to create a basic HTML document, the structure of an HTML document, common HTML tags, and metadata tags. It explains that an HTML document contains <html>, <head>, and <body> tags and describes what each tag is used for. It also lists some common tags like <title>, <p>, and <h1> and explains how to open a basic HTML file in a text editor and web browser to view it. Finally, it discusses HTML meta tags which can provide metadata about the document.
This document provides an introduction to HTML, including how to create basic HTML documents and common HTML tags. It explains that HTML documents have a basic structure of <html>, <head>, and <body> tags. The <head> contains metadata like the <title>. The <body> contains visible page content. It also describes some core HTML attributes like id, title, class, and style that can be used on most tags. Meta tags are explained as a way to provide metadata about documents.
HTML is the standard markup language used to create web pages. It provides a structure and layout for text, images, and other content. The document explains the basic components of an HTML page, including the <head> and <body> tags, common text formatting tags, links, lists, and tables. It recommends learning HTML tags through online resources or by examining the source code of existing web pages, and emphasizes starting simply with tags like <head>, <title>, <h2>, and <p>.
This document provides an introduction to HTML (Hypertext Markup Language) and describes the basic structure and tags used in an HTML document. It explains that HTML documents use markup tags to define headings, paragraphs, lists and other elements. The key tags are <html> to define an HTML document, <head> for page header info like the <title>, and <body> for the visible page content. It provides examples of basic HTML documents and describes common tags like <p> for paragraphs and <h1> for headings.
The document provides an introduction to understanding internet basics for Visual Basic programmers. It discusses that Visual Basic allows programmers to easily produce functional web applications regardless of their experience level with internet technology. It describes internet technology as another area for development, noting how incorporating HTML and security features is similar to traditional Visual Basic development. The document also explains how applying internet technology enables extending development skills in new ways, such as reducing costs and maintenance through web deployment.
HTML is a markup language used to describe and structure web pages. It uses tags to define headings, paragraphs, links, images, and other content. An HTML file contains a head and body section. The head contains meta information about the page like the title. The body contains the visible page content. Common tags include headings, paragraphs, links, images, and divs to group content. Attributes provide extra information about elements.
Environmental Sciences is the scientific study of the environmental system and
the status of its inherent or induced changes on organisms. It includes not only the study
of physical and biological characters of the environment but also the social and cultural
factors and the impact of man on environment.
Infrastructure for Tracking Information Flow from Social Media to U.S. TV New...Himarsha Jayanetti
This study examines the intersection between social media and mainstream television (TV) news with an aim to understand how social media content amplifies its impact through TV broadcasts. While many studies emphasize social media as a primary platform for information dissemination, they often underestimate its total influence by focusing solely on interactions within the platform. This research examines instances where social media posts gain prominence on TV broadcasts, reaching new audiences and prompting public discourse. By using TV news closed captions, on-screen text recognition, and social media logo detection, we analyze how social media is referenced in TV news.
The human eye is a complex organ responsible for vision, composed of various structures working together to capture and process light into images. The key components include the sclera, cornea, iris, pupil, lens, retina, optic nerve, and various fluids like aqueous and vitreous humor. The eye is divided into three main layers: the fibrous layer (sclera and cornea), the vascular layer (uvea, including the choroid, ciliary body, and iris), and the neural layer (retina).
Here's a more detailed look at the eye's anatomy:
1. Outer Layer (Fibrous Layer):
Sclera:
The tough, white outer layer that provides shape and protection to the eye.
Cornea:
The transparent, clear front part of the eye that helps focus light entering the eye.
2. Middle Layer (Vascular Layer/Uvea):
Choroid:
A layer of blood vessels located between the retina and the sclera, providing oxygen and nourishment to the outer retina.
Ciliary Body:
A ring of tissue behind the iris that produces aqueous humor and controls the shape of the lens for focusing.
Iris:
The colored part of the eye that controls the size of the pupil, regulating the amount of light entering the eye.
Pupil:
The black opening in the center of the iris that allows light to enter the eye.
3. Inner Layer (Neural Layer):
Retina:
The light-sensitive layer at the back of the eye that converts light into electrical signals that are sent to the brain via the optic nerve.
Optic Nerve:
A bundle of nerve fibers that carries visual signals from the retina to the brain.
4. Other Important Structures:
Lens:
A transparent, flexible structure behind the iris that focuses light onto the retina.
Aqueous Humor:
A clear, watery fluid that fills the space between the cornea and the lens, providing nourishment and maintaining eye shape.
Vitreous Humor:
A clear, gel-like substance that fills the space between the lens and the retina, helping maintain eye shape.
Macula:
A small area in the center of the retina responsible for sharp, central vision.
Fovea:
The central part of the macula with the highest concentration of cone cells, providing the sharpest vision.
These structures work together to allow us to see, with the light entering the eye being focused by the cornea and lens onto the retina, where it is converted into electrical signals that are transmitted to the brain for interpretation.
he eye sits in a protective bony socket called the orbit. Six extraocular muscles in the orbit are attached to the eye. These muscles move the eye up and down, side to side, and rotate the eye.
The extraocular muscles are attached to the white part of the eye called the sclera. This is a strong layer of tissue that covers nearly the entire surface of the eyeball.he layers of the tear film keep the front of the eye lubricated.
Tears lubricate the eye and are made up of three layers. These three layers together are called the tear film. The mucous layer is made by the conjunctiva. The watery part of the tears is made by the lacrimal gland
Examining Visual Attention in Gaze-Driven VR Learning: An Eye-Tracking Study ...Yasasi Abeysinghe
This study presents an eye-tracking user study for analyzing visual attention in a gaze-driven VR learning environment using a consumer-grade Meta Quest Pro VR headset. Eye tracking data were captured through the headset's built-in eye tracker. We then generated basic and advanced eye-tracking measures—such as fixation duration, saccade amplitude, and the ambient/focal attention coefficient K—as indicators of visual attention within the VR setting. The generated gaze data are visualized in an advanced gaze analytics dashboard, enabling us to assess users' gaze behaviors and attention during interactive VR learning tasks. This study contributes by proposing a novel approach for integrating advanced eye-tracking technology into VR learning environments, specifically utilizing consumer-grade head-mounted displays.
1. unitii.md 2023-10-17
1 / 25
LESSON NOTES
WEB PROGRAMMING
Subject Code:
3ZA
Year:
II
Semester:
III
Unit:
II
Syllabus
1. HTML - Introduction
2. Getting Started
3. Creating and saving an HTML document
4. Document Layout of HTML Page
5. HTML elements
6. Some other formatting Styles
7. Hypertext Links
HTML - Introduction
What is HTML?
2. unitii.md 2023-10-17
2 / 25
HTML Stands for HyperText Markup Language, where
HyperText stands for Link between web pages.
Markup Language means Text between tags that define the structure.
HTML is a markup language that is used to create web pages. It defines how the web page looks and
how to display content with the help of elements. It forms or defines the structure of our Web Page,
thus it forms or defines the structure of our Web Page. We must remember to save your file with .html
extension.
Applications of HTML
HTML is used for various purposes. Let us take a look at them
1. Web Pages Development HTML is famously used for creating web pages on the world wide web.
Every web page contains a set of HTML tags and hyperlinks which are used to connect other pages.
Every page on the internet is written using HTML.
2. Navigating the Internet Navigating on the internet would have been quite a tedious task without
HTML. The anchor tags of HTML allows us to link pages and navigate easily. Imagine our life without
anchor tags, you would literally have to enter URL everytime. Using achor tags, you can also navigate
within a webpage.
3. Embedding Images and Videos HTML allows us to embed images and videos with ease and gives us
features to adjust height, position and even rendering type. You can adjust controls, thumbnails,
timestamps and much more for videos. Earlier this was done using Flash and HTML has made it easier
with the help of <video> tag.
4. Clinet-side storage HTML5 has made client-side storage possible using localStorage and IndexD due
to which we no longer need to reply on Cookies. Both of these tactics have their own set of rules and
characteristics. String-based hash-table storage is provided by localStorage. Its API is straightforward,
with setItem, getItem, and removeItem functions available to developers. On the other hand, IndexDB is
a larger and more capable client-side data store. With the user’s permission, the IndexDB database can
be enlarged.
5. Game development Although you cannot create complex high-end video games with HTML, the
<canvas> element of HTML can be used to make 2D and 3D games using CSS and JavaScript which can
be run on browsers.
6. Data entry support With the usage of new HTML5 standards in all the latest browsers, developers can
simply add the tags for required fields, text, data format, etc. and get the data. HTML5 now has several
new attributes for data-entry and validation purposes.
7. Interacting with Native APIs With the help of HTML, you can interact with your Operating system.
With this feature, you can easily drag files onto a web page to upload, full-screen a video, and much
more.
Features of HTML
1. The learning curve is very easy (easy to modify)
2. Creating effective presentations
3. unitii.md 2023-10-17
3 / 25
3. Adding Links wherein we can add references
4. Can display documents on platforms like Mac, Windows, Linux, etc
5. Adding videos, graphics, and audios making it more attractive
6. Case insensitive language
HTML Editor
Simple editor: Notepad
Visual Studio Code
Notepad++
Atom
Best editor: Sublime Text
How does HTML work?
The average website includes several different HTML pages.
For instance, a home page, an about page, and a contact page would all have separate HTML files.
HTML documents are files that end with a .html or .htm extension.
A web browser reads the HTML file and renders its content so that internet users can view it.
All HTML pages have a series of HTML elements, consisting of a set of tags and attributes.
HTML elements are the building blocks of a web page.
A tag tells the web browser where an element begins and ends, whereas an attribute describes the
characteristics of an element.
The three main parts of an element are:
1. Opening tag – used to state where an element starts to take effect. The tag is wrapped with opening
and closing angle brackets. For example, use the start tag <p> to create a paragraph.
2. Content – this is the output that other users see.
3. Closing tag – the same as the opening tag, but with a forward slash before the element name. For
example, </p> to end a paragraph.
The combination of these three parts will create an HTML element:
<p>This is how you add a paragraph in HTML.</p>
Another critical part of an HTML element is its attribute, which has two sections – a name and attribute value.
The name identifies the additional information that a user wants to add, while the attribute value gives further
specifications.
For example, a style element adding the color purple and the font-family verdana will look like this:
<p style="color:purple;font-family:verdana">This is how you add a paragraph in
HTML.</p>
4. unitii.md 2023-10-17
4 / 25
Getting Started
HTML Skeleton
<!DOCTYPE html>
<html>
<head>
<title>Title of the document</title>
</head>
<body>
You can declare all the elements
</body>
</html>
HTML Basic
<!DOCTYPE html>
Instruction to the browser about the HTML version.
<html>
1. Root element which acts as a container to hold all the code
2. The browser should know that this is an HTML document
3. Permitted content: One head tag followed by one body tag
<head>
1. Everything written here will never be displayed in the browser
2. It contains general information about the document
3. Title, definitions of CSS and script sheets
4. Metadata(information about the document)
<body>
1. Everything written here will be displayed in the browser
2. Contains text, images, links that can be achieved through tags
3. Examples:
- <p> This is our first paragraph. </p>
- <a href=”http://www.google.com”>Go To Google</a>
- <img src=”photo.jpg”>
HTML Comment
5. unitii.md 2023-10-17
5 / 25
Comments don’t render on the browser
Helps to understand our code better and makes it readable.
Helps to debug our code
Three ways to comment:
1. Single line
2. Multiple lines
3. Comment tag //Supported by IE
How Does HTML Work?
What are HTML tags?
Essentially, HTML tags are markers which tell the browser how the enclosed text should be displayed.
Here’s a simple example:
<b>This text should be bold.</b>
In this case, <b> and </b> are the HTML tags. They are marking the enclosed text as “bold”—hence, the
“markup” element of HTML. We’ll explain how to actually write tags in the next section.
Once the document is complete, the author saves it as a html file and opens it in their internet browser.
The browser then reads the file and follows the instructions to render the page in a certain way—as
provided by the HTML tags.
So, when you use the “bold” tags, you’re essentially telling the browser to display this sentence in bold:
<b>This text should be bold.</b>
When the browser reads this, it knows to display the sentence as described: This text should be bold. Of
course, the HTML tags themselves are not displayed in the browser (unless you make a mistake writing
them!).
Tags
HTML tags are written inside angle brackets, and tend to come in pairs—so, they consist of both an
opening and a closing tag.
For example, the <p> tag is used to indicate a new paragraph. The opening tag is written as follows:
<p>. After this tag, you write your paragraph. To finish, add your closing tag, which is the same as the
opening tag but with a forward slash. In this case, it would be: </p>.
A pair of tags with text enclosed is known as an element. Here are some examples of common HTML
elements and their corresponding tags:
<h1>This is a heading</h1>
<p>This is a paragraph</p>
<b>This is a bold sentence</b>
<i>This is an italic sentence</i>
6. unitii.md 2023-10-17
6 / 25
Most HTML tags follow this open-and-closing pattern, but there are also some tags which only need an
opening tag to be valid. These are known as singleton tags, and include things like <br> to indicate a line
break, and <img> for including an image. The browser will understand and act on these tags without the need
for a closing tag.
Attributes
Attributes provide extra information about the text contained within the tags.
For example, if you wanted to hyperlink the phrase “my website” in your HTML document, you would
first use the tag pairs <a> and </a> to specify that the text should be linked.
To tell the browser where the text should be linked to—i.e. the link address—you use the href attribute.
Attributes, like the text, are always enclosed within the tags:
HTML: <a href=”https://www.google.com”>My website</a>
Most Used HTML Tags and HTML Elements
Block-Level Elements
A block-level element takes up the entire width of a page. It always starts a new line in the document. For
example, a heading element will be in a separate line from a paragraph element.
Every HTML page uses these three tags:
1. <html> tag is the root element that defines the whole HTML document.
2. <head> tag holds meta information such as the page’s title and charset.
3. <body> tag encloses all the content that appears on the page.
Other popular block-level tags include:
Heading tags – these range from <h1> to <h6>, where heading h1 is largest in size, getting smaller as
they move up to h6.
Paragraph tags – are all enclosed by using the <p> tag.
List tags – have different variations. Use the <ol> tag for an ordered list, and use <ul> for an
unordered list. Then, enclose individual list items using the <li> tag.
Inline Elements
An inline element formats the inner content of block-level elements, such as adding links and
emphasized strings.
Inline elements are most commonly used to format text without breaking the flow of the content.
For example, a <strong> tag would render an element in bold, whereas the <em> tag would show it in
italics.
Hyperlinks are also inline elements that use an <a> tag and an href attribute to indicate the link’s
destination:
<a href="https://example.com/">Click me!</a>
8. unitii.md 2023-10-17
8 / 25
You can create your first HTML page by the following steps:
Step 1: Open the Text Editor
In this step, we have to open any text editor such as Notepad or Notepad++ for writing an HTML code. The
following image is the screenshot of the text editor (notepad++) for writing the HTML code.
Step 2: Type the HTML code.
In this step, we have to type the HTML code in the text editor. The HTML code is composed of various tags
and always begins with the opening tag of HTML and complete with the closing tag of HTML.
The following block describes the syntax for creating any HTML page:
<HTML>
<HEAD>
<!-- The Head tag is used to create a title of web page, CSS syntax for a web
page, and helps in written a JavaScript code. -->
</HEAD>
<BODY>
<!-- The Body tag is used to display the content on a web page, which is specified
between the body tag. -->
</BODY>
</HTML> <!-- It is the opening tag of any HTML -->
9. unitii.md 2023-10-17
9 / 25
In the above syntax, some important tags or elements are used, which are given below:
<HTML>: It is the opening tag of any HTML code.
<HEAD>: The Head tag is used to create a title of the web page, CSS syntax for a web page, and helps in
written a JavaScript code The <head> must be closed before the opening of <body> tag.
<BODY>: The Body tag is used to display the content or text on a web page, which is specified between
the body tag.-->
</HTML>: It is the Closing tag of any HTML code.
Example: The following example creates a simple HTML page as an example through which you can
understand easily:
<HTML> <!-- It is the opening tag of any HTML -->
<HEAD>
<!-- The Head tag is used to create a title of web page, CSS syntax for a web
page, and helps in written a JavaScript code. -->
<title> <!-- This tag is used to display the title of the Web Page -->
Simple HTML Page
</title>
<script>
<!-- This tag helps in written the JavaScript Code -->
</script>
<style>
/* This tag is used to create a Cascading Style Sheet for displaying the
attractive web page. */
</style>
</HEAD>
<BODY>
<center> <!-- This tag align the text as center -->
JavaTpoint
<!-- The Body tag is used to display the content on a web page which is specify
between the body tag. -->
</center>
</BODY>
</HTML>
Step 3: Save the HTML code.
After typing the complete HTML code, we have to save that file in a folder with .html extension. We can easily
save the html file by clicking on the File menu and then click on Save As option. After that, type the file name
with .html extension. The following screenshot describes how we save the above html code in a text editor.
10. unitii.md 2023-10-17
10 / 25
Step 4: Run the HTML file.
At the last step, we have to execute or run an HTML file from the location where we saved the file. The file will
run on a default browser. Consider the below output:
Document Layout of HTML Page
11. unitii.md 2023-10-17
11 / 25
HTML Layout
HTML layout refers to the way in which the content of a website is organized and structured. It makes the
website easy to navigate. For example,
HTML Layout Elements
There are various HTML Layout elements. They are as follows:
<header> tag
A <header> tag defines the document's header. For example,
<header>Programiz</header>
12. unitii.md 2023-10-17
12 / 25
<nav> tag
The <nav> tag represents a section of a page that links to other pages or to parts within the page.
<section> tag
The <section> tag in HTML represents a standalone section of content within a document.
<article> tag
The <article> tag in HTML represents a self-contained piece of content that can be reused.
<aside> tag
The <aside> tag is used to represent a portion of a document that is indirectly related to the main content. It
is most commonly used as a sidebar in the document.
<footer> tag
The HTML <footer> tag defines the footer of the HTML document or section.
<details> tag
The <details> tag provides additional details that the user can view or hide on demand. For example,
<details>
<summary>Click me</summary>
<p>Hidden content</p>
</details>
Example1
Let's create a simple layout using CSS.
<body>
<div class="box">
<section class="yellow">
</section>
<aside class="blue">
</aside>
13. unitii.md 2023-10-17
13 / 25
</div>
</body>
<style>
.box {
display: flex;
height: 200px;
}
.blue {
width:65%;
height: 200px;
background-color: blue;
}
.yellow {
width: 35%;
height: 200px;
background-color: yellow;
}
</style>
In the above example, we have created a <div> with a class box. Inside it, we have a <section> and an
<aside> element with class yellow and blue respectively. We have used CSS to arrange the elements.
Notice, the code,
.box {
display: flex;
height: 200px;
}
Here,
display: flex - arranges the box next to each other in a row
height: 200 px - sets the height to 200 pixels
14. unitii.md 2023-10-17
14 / 25
Then, we have also used CSS for the <div> with class blue and yellow.
.blue {
width:65%;
height: 200px;
background-color: blue;
}
.yellow {
width: 35%;
height: 200px;
}
Here,
width - sets the width of <div>
height - sets the height of <div>
background-color - sets the background color of <div>
Example2
Let's create a simple layout using CSS.
<body>
<header>
<h2>Title</h2>
</header>
<section>
<nav>
<ul>
<li><a href="#">Home</a></li>
<li><a href="#">Learn HTML</a></li>
<li><a href="#">About Us</a></li>
</ul>
</nav>
<article>
<h1>Home</h1>
<p>This is a home page.</p>
</article>
</section>
<footer>
<p>Footer</p>
</footer>
</body>
<style>
* {
box-sizing: border-box;
}
header {
background-color: lightblue;
16. unitii.md 2023-10-17
16 / 25
HTML elements
In HTML, an element is a section of an HTML document.
Some HTML elements represent visible components on a web page, such as text, images, or buttons,
while others denote different sections of the page or provide meta-information about the document.
"In the code itself, HTML elements are created with tags. An HTML tag consists of text between angle brackets
(<>)."
Most HTML elements consist of three parts:
1. The opening tag (or start tag) marks where the element’s content begins (<p> in the example above).
2. The closing tag (or end tag) marks the end of the element’s content (</p> above). The closing tag is
identical to the opening tag with the addition of a forward slash (/) after the first angle bracket.
3. The content is placed between the element’s opening and closing tags (This is paragraph text. above).
17. unitii.md 2023-10-17
17 / 25
Empty HTML Elements
While most HTML elements are written with an opening and closing tag, some elements consist of a
single tag and do not have closing tags or content. These are called empty elements.
One empty element you’ll see often is the line break element, which adds a line break between text.
As you can see, simply using <br> creates the line break, no closing tag necessary. Other common
empty elements include <img> (image), <meta>, <link>, and <input>.
HTML Attributes
HTML elements can also contain attributes. Attributes are extra code placed inside the opening tag of an
element that provides additional information about the element. An attribute may be optional or required.
HTML Element Nesting
HTML elements can also be placed inside of other elements — this is called nesting and is key to how
HTML documents are assembled.
Going back to our <p> example, let’s see how an anchor element, which creates a hyperlink, is nested
inside paragraph text. Here, the anchor element is placed between the opening and closing tags of the
paragraph element.
Block-Level Elements
A block-level element takes up the entire width of a page. It always starts a new line in the document. For
example, a heading element will be in a separate line from a paragraph element.
Every HTML page uses these three tags:
18. unitii.md 2023-10-17
18 / 25
1. <html> tag is the root element that defines the whole HTML document.
2. <head> tag holds meta information such as the page’s title and charset.
3. <body> tag encloses all the content that appears on the page.
Other popular block-level tags include:
Heading tags – these range from <h1> to <h6>, where heading h1 is largest in size, getting smaller as
they move up to h6.
Paragraph tags – are all enclosed by using the <p> tag.
List tags – have different variations. Use the <ol> tag for an ordered list, and use <ul> for an
unordered list. Then, enclose individual list items using the <li> tag.
Inline Elements
An inline element formats the inner content of block-level elements, such as adding links and
emphasized strings.
Inline elements are most commonly used to format text without breaking the flow of the content.
For example, a <strong> tag would render an element in bold, whereas the <em> tag would show it in
italics.
Hyperlinks are also inline elements that use an <a> tag and an href attribute to indicate the link’s
destination:
<a href="https://example.com/">Click me!</a>
Elements
<a>
Creates a link to another page or to a location in the current page.
<abbr>
Indicates an acronym or abbreviation of a longer word or phrase.
<acronym>
Creates text that will be displayed when hovered over.
<applet>
Used to embed Java applets in HTML documents but is no longer supported.
<audio>
Represents an interface for adding audio content to the page.
<b>
Used to draw attention to a section of text, usually rendered in boldface.
<basefont>
Used to be used to set the font of text. This is now deprecated.
<blink>
Used to make text flash on and off and is now obsolete, deprecated, and non-
19. unitii.md 2023-10-17
19 / 25
standard.
<blockquote>
Represents a section of a document which contains a longer quotation, usually
spanning multiple lines.
<br>
Represents a break in text. It is used when text needs to span multiple lines
rather than being in-line, such as in an address.
<button>
Represents a button meant to be clicked by the user.
<canvas>
Creates graphics and animations in the page for JavaScript and WebGL to interact
with
<center>
Displays its contents centered horizontally in the containing element. This is now
deprecated and CSS should be used instead.
<cite>
Represents a citation to a referenced work such as a book, a song, or a painting.
<code>
Represents source code contained in the text.
<datalist>
Displays pre-defined values to a user while typing into an input box.
<dd>
Describes details found inside a <dl> element. It usually comes with at least one
corresponding <dt> term tag.
<del>
Shows text that is to be removed from a document, usually rendered in strike-
through text.
<div>
Represents a generic division of content. It has no semantic meaning, but will
separate its contents from the rest of the document.
<dl>
Displays terms and details, commonly for metadata purposes.
<dt>
Describes a term found inside a <dl> tag. It usually comes with at least one
corresponding <dd> details tag.
<em>
Represents text which is emphasized. Browsers will show the enclosed text in
italics, by default."
<embed>
20. unitii.md 2023-10-17
20 / 25
Inserts external content such as a video, image, page, and more.
<font>
Used to be used to set the font characteristics of a text. This is now deprecated.
<form>
Represents an interface to collect and submit user supplied information. This can
include open ended text inputs, radio buttons, calendar information, and more.
<h1> - <h6>
Represents a text heading for a section of content, with <h1> being the highest
level of heading and <h6> being the lowest.
<head>
Represents a collection of metadata related to the current document. It is an
immediate child of the `<html>` element and may include other tags such as
<title>, <link>, <style>, and <script>.
<hr>
Represents a semantic, horizontal line break between text elements.
<html>
Represents the entire HTML document.
<i>
Used to set off HTML text for some reason, as idiomatic, technical, taxonomical
and so on. Typically rendered as italic.
<iframe>
Represents a container used to embed a second web page inside the current one. It
can be used for content from the same domain as the parent, or even from a second
domain.
<img>
Displays an image on the web page.
<input>
Creates an interactive element, usually used within a form to allow user input. It
can be used to make text boxes, color pickers, date pickers, and other UI
elements.
<kbd>
Emphasizes characters to look like keys on a keyboard.
<label>
Identifies captions for other elements in an HTML document.
<li>
Represents a single item in a list of items. It and the other list items must be
wrapped in an <ol>, <ul>, or <menu> tag.
<link>
Connects the current page with an external file.
21. unitii.md 2023-10-17
21 / 25
<menu>
Represents an unordered list of items with more semantic meaning than a regular ul
element.
<meta>
Represents an interface to provide metadata pertaining to the document. Metadata
is data that is used to describe the document that contains it.
<noscript>
Displays content within if JavaScript is disabled in the browser or not supported.
<object>
Represents an external resource such as an image, a nested browsing context, or
content to be handled by a browser plugin.
<ol>
Represents an ordered list of items.
<option>
Represents one option in a dropdown created by the select tag.
<output>
Displays the result of a calculation or user action.
<p>
Contains and displays a block of text that defines a paragraph.
<param>
Used to pass parameters to a resource defined in an object tag.
<picture>
Represents multiple possible image sources to be applied to different devices and
screen-sizes.
<q>
Used to represent a brief inline quotation.
<s>
Represents strike-through text that is no longer need, accurate, or correct.
<script>
Used to insert runnable code into a document, usually JavaScript. Can be used both
to include a script within the HTML document, or to load an external script from
another source.
<select>
Creates a drop-down list for the user to select from a number of option elements.
<source>
Represents an interface for adding source content to the page.
<span>
Used for grouping related text or elements for styling and scripting.
22. unitii.md 2023-10-17
22 / 25
<strong>
Used to identify text that is very important, or urgent.
<style>
Applies CSS styles to an HTML document.
<table>
Represents an interface for adding tabular data to the page. Tables are two
dimensional, made up of rows and columns, and can contain many types of content.
<textarea>
Displays multi-line plain-text input.
<track>
An HTML element that specifies subtitles, closed captioning, and other text files
for media elements.
<u>
Displays HTML text with a non-textual annotation. The default rendering of this is
a solid underline.
<ul>
Represents an unordered list of items.
<video>
Represents an interface for adding video content to the page.
Some other formatting Styles
HTML Formatting is a process of formatting text for better look and feel.
HTML provides us ability to format text without using CSS.
There are many formatting tags in HTML. These tags are used to make text bold, italicized, or
underlined.
There are almost 14 options available that how text appears in HTML and XHTML.
In HTML the formatting tags are divided into two categories:
1. Physical tag: These tags are used to provide the visual appearance to the text.
2. Logical tag: These tags are used to add some logical or semantic value to the text.
Element name Description
<b> This is a physical tag, which is used to bold the text written between it.
<strong> This is a logical tag, which tells the browser that the text is important.
<i> This is a physical tag which is used to make text italic.
23. unitii.md 2023-10-17
23 / 25
Element name Description
<em> This is a logical tag which is used to display content in italic.
<mark> This tag is used to highlight text.
<u> This tag is used to underline text written between it.
<tt> This tag is used to appear a text in teletype. (not supported in HTML5)
<strike> This tag is used to draw a strikethrough on a section of text. (Not supported in HTML5)
<sup> It displays the content slightly above the normal line.
<sub> It displays the content slightly below the normal line.
<del> This tag is used to display the deleted content.
<ins> This tag displays the content which is added
<big> This tag is used to increase the font size by one conventional unit.
<small> This tag is used to decrease the font size by one unit from base font size.
Hypertext Links
A link is an element that, when clicked, redirects the user to another web page.
Links are usually text-based, but they can also be an image or otherwise.
To create a link use the <a> tag -- this is called an anchor tag.
Syntax
The syntax for a link:
<a href="url">Link text</a>
The <a> tag defines an HTML link; a stands for anchor.
The href attribute defines the destination address (the URL or page the user will be taken to).
Link text is the visible part which will be displayed as a clickable text.
Note: Links are also known as hyperlinks -- there is no difference, they are the same.
Local Links
1. A local link points to a page on the same website -- i.e. the same domain.
2. Local links have a relative URL without the https://www.mysite.com part.
3. Most websites use local links almost exclusively.
24. unitii.md 2023-10-17
24 / 25
<p>
Please visit our <a href="/sql"> SQL Tutorial </a>
</p>
Note: Links that redirect to an external website are refered to as external links. The Google link above
is an example of an external link.
Link Colors
By default, a link will appear in these colors (all browsers support this):
An unvisited link is underlined and blue.
A visited link is underlined and purple.
An active link is underlined and red.
Link target Attribute
The target attribute specifies where to open the linked page. It can be one of the following values:
VALUE DESCRIPTION
_self Opens the page in the same tab/window. This is the default.
_blank Opens the page in a new tab.
_parent Opens the page in the parent iframe. In the same iframe if there is no parent.
_top Opens the page in the topmost part of the iframe. In the same iframe if there is no topmost.
framename Opens the page in a named iframe.
Example
<a href="/about-us.php" target="_top">About Us</a>
<a href="https://www.google.com/" target="_blank">Google</a>
<a href="images/sky.jpg" target="_parent">
<img src="sky-thumb.jpg" alt="Cloudy Sky">
</a>
Tip: If your web page is placed inside an iframe, you can use the target="_top" on the links to break
out of the iframe and show the target page in full browser window.
Creating Bookmark Anchors
You can also create bookmark anchors to allow users to jump to a specific section of a web page. Bookmarks
are especially helpful if you have a very long web page.
25. unitii.md 2023-10-17
25 / 25
Creating bookmarks is a two-step process: first add the id attribute on the element where you want to jump,
then use that id attribute value preceded by the hash sign (#) as the value of the href attribute of the <a> tag,
as shown in the following example:
<a href="#sectionA">Jump to Section A</a>
<h2 id="sectionA">Section A</h2>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit...</p>
Tip: You can even jump to a section of another web page by specifying the URL of that page along
with the anchor (i.e. #elementId) in the href attribute, for example, <a
href="mypage.html#topicA">Go to TopicA</a>.
Creating Download Links
You can also create the file download link in exactly the same fashion as placing text links. Just point the
destination URL to the file you want to be available for download.
In the following example we've created the download links for ZIP, PDF and JPG files.
<a href="downloads/test.zip">Download Zip file</a>
<a href="downloads/masters.pdf">Download PDF file</a>
<a href="downloads/sample.jpg">Download Image file</a>
Note: When you click a link that points to a PDF or image file, the file is not downloaded to your hard
drive directly. It will only open the file in your web browser. Further you can save or download it to
your hard drive on a permanent basis.