The words you are searching are inside this book. To get more targeted content, please make full-text search by clicking here.
Discover the best professional documents and content resources in AnyFlip Document Base.
Search
Published by aayushbhatta62, 2021-09-23 10:48:50

JBD Computer Studies Book 9

JBD Computer Studies Book 9

Keywords: JBD Publication, Kathmandu, Latest edition, Nepal, JBD Computer Studies Book 9, aayushbhatta62

The Working Group on E-Government in the Developing World has identified
broad categories of goals commonly pursued for E-government. E-government is
a means to accomplish these broader social goals, goals that move beyond mere
efficiency of government processes to that of overall reform and development.
The goals of E-Government are:
• Creating a better business environment
• Improving the productivity
• Strengthening good governance and broadening public participation
• Improving the productivity and efficiency of government agencies
• Improving the quality of life for disadvantaged communities
• Improving the business environment in the country for private sector
development and to attract foreign direct investment.

Advantages of e-Government
• E-government is rapidly finding favour with governments across the

world. By using the internet and other modern communication technology,
governments can hope to reach out to the populace in larger numbers.
• The internet is a powerful medium for customer relationship management
and it enables governments to extend service more effectively to the people.
E-government models are built around objectives that include better use
of information, quicker dissemination of information, transparency in
government-people transactions, and creating services that cover as broad a
spectrum of society as possible or interaction history.
• E-government also allows governments to participate in business transactions
in a more profitable manner.
• Communication between the various government departments improves,
information sharing is much better which aids governance, business
transactions and stimulates the growth of a new economy.

Disadvantages of e-Government
• The main disadvantage of an electronic government is to move the government

services into an electronic based system. This system loses the person to
person interaction which is valued by a lot of people.
• The implementation of an e-government does have certain constraints.
Literacy of the users and the ability to use the computer, users who do not
know how to read and write would need assistance.
• Studies have shown that there is potential for a reduction in the usability of
government online due to factors such as the access to Internet technology
and usability of services.

JBD
Computer Studies-9 101

Main domains of e-Government
There are three main domains of e-government are:
Improving government processes: eAdministration
eGovernment initiatives within this domain deal particularly with improving the
internal workings of the public sector. They include:
• Cutting process costs : improving the input:output ratio by cutting financial

costs and/or time costs.
• Managing process performance: planning, monitoring and controlling the

performance of process resources (human, financial and other).
• Making strategic connections in government: connecting arms, agencies,

levels and data stores of government to strengthen capacity to investigate,
develop and implement the strategy and policy that guides government
processes.
• Creating empowerment : transferring power, authority and resources for
processes from their existing location to new locations.

Connecting Citizens: eCitizens and eServices
Such initiatives deal particularly with the relationship between government and
citizens: either as voters/stakeholders from whom the public sector should derive
its legitimacy, or as customers who consume public services. They include:
• Talking to citizens : providing citizens with details of public sector activities.

This mainly relates to certain types of accountability: making public servants
more accountable for their decisions and actions.
• Listening to citizens:increasing the input of citizens into public sector decisions
and actions. This could be flagged as either democratisation or participation.
• Improving public services : improving the services delivered to members of
the public along dimensions such as quality, convenience and cost.

Building External Interactions: eSociety
Such initiatives deal particularly with the relationship between public agencies
and other institutions - other public agencies, private sector companies, non-p
Working better with business: improving the interaction between government
and business. This includes digitising regulation of, procurement from, and
services to, business to improve quality, convenience and cost.
• Developing communities : building the social and economic capacities and

capital of local communities.
• Building partnerships : creating organisational groupings to achieve economic

and social objectives. The public sector is almost always one of the partners,
though occasionally it acts only as a facilitator for others.

JBD
102 Computer Studies-9

Types of e-Government services
The four types of e-government services are Government-to-Citizen
(G2C),Government-to-Business(G2B),Government-to-Employee(G2E),and
Government-to-Government (G2G).

Government-to-Citizen (G2C)
Government-to-Citizen (G2C) is the online non-commercial interaction between
local and central Government and private individuals. It includes information
dissemination to the public, basic citizen services such as license renewals,
ordering of birth/death/marriage certificates and filing of income taxes, as well
as citizen assistance for such basic services as education, health care, hospital
information and libraries. It makes public services and information accessible to
all. For example Government sectors become visibly open to the public domain
via a Web Portal. One such web portal is Government Gateway.

Government-to-Business (G2B)
Government-to-Business (G2B) is the online non-commercial interaction between
local and central government and the commercial business sector. It includes
dissemination of policies, memos, rules and regulations. Business services offered
include obtaining current business information, downloading application forms,
renewing licenses, registering businesses, obtaining permits, payment of taxes
and an online government-supplier exchange for the purchase of goods and
services by government.

Government-to-Employee (G2E)
Government-to-Employee (G2E) is the online non-commercial interaction between
government organization and the government employees. It includes provision
of human resources training and development that improve the bureaucracy’s
day-to-day functions and dealings with citizens.

Government-to-Government (G2G)
Government-to-Government (G2G) is the online non-commercial interaction
between Government organisations, departments, and authorities and other
Government organisations, departments and authorities. G2G services take place
at two levels: at the local or domestic level and at the international level. G2G
services are transactions between the central/national and local governments,
and between department-level and attached agencies and bureaus. At the same
time, G2G services are transactions between governments, and can be used as an
instrument of international relations and diplomacy.

JBD
Computer Studies-9 103

C Dompu- ictionary

e-Goverance : Government’s use of information technology to
exchange information and services with citizens,
businesses and other arms of government.

IT : A technology that is used to store, communicate and
manipulate information.

G2C : The online non-commercial interaction between local
and central Government and private individuals.

G2B : The online non-commercial interaction between local
and central government and the commercial business
sector.

G2E : The online non-commercial interaction between
government organization and the government
Recap employees.

• Information technology is a technology that is used to store, communicate
and manipulate information.

• The world’s least developed countries including Nepal have availed
themselves of the opportunity to rapidly develop education, health,
agriculture, tourism, trade and various other sectors using information
technology (IT).

• In the coming years, globally, there will be a significant difference in the
economic conditions of the countries developed in the field of information
technology and of the countries lagging behind in this field.

• The government shall act as a promoter, facilitator and regulator.

• e-Government is a general term describing the use of technologies to
facilitate the operation of government and the disbursement of government
information and services.

• e-Government deals heavily with Internet applications to aid in governments,
but also covers a number of non-Internet concerns.

• e-Government improves the productivity and efficiency of government
agencies.

• e-Government improves the quality of life for disadvantaged communities

• The four types of e-government services are-Government-to-Citizen (G2C),
Government-to-Business (G2B), Government-to-Employee (G2E), and
Government-to-Government (G2G).

JBD
104 Computer Studies-9

Review Yourself

1. State whether the following statements are true or false.
a. As the role of information technology in society has increased,
opportunities for crime have been created that never existed before.
b. The main purpose of IT Policy in Nepal is to place Nepal on the global
map of IT within the next five years.
c. The information technology policy shall be formulated in Nepal to
establish knowledge-based industries.
d. e-Government is a highly general/generic term usually referring to the
provision of services via the Internet.
e. e-Government creates a better business environment.

2. Fill in the blanks.
a. __________________ will be one of the key factors driving progress in
the 21st century- it will transform the way we live, learn, work and play.
b. ________________ is a technology that is used to store, communicate
and manipulate information.
c. _____________ is the government’s use of information technology to
exchange information and services with citizens, businesses and other
arms of government.
d. _________________ is the online non-commercial interaction between
local and central government and the commercial business sector.
e. ___________________ is the online non-commercial interaction between
government organization and the government employees.

3. Give the full form of the following abbreviations.

IT, NITC, NITDC, NITCC, G2C, G2B, G2E, G2G

4. Name the technical term for each of the following.

a. Government’s use of information technology to exchange information
and services with citizens, businesses and other arms of government.

b. A technology that is used to store, communicate and manipulate
information.

c. The online non-commercial interaction between local and central
Government and private individuals.

JBD
Computer Studies-9 105

d. The online non-commercial interaction between local and central
government and the commercial business sector.

e. Theonlinenon-commercialinteractionbetweengovernmentorganization
and the government employees.

5. Match the following.

e-Goverance The buying and selling of goods and services on the
Internet.

IT Government’s use of information technology to
exchange information and services with citizens,
businesses and other arms of government.

e-Commerce The online non-commercial interaction between local
and central Government and private individuals.

e-Education A technology that is used to store, communicate and
manipulate information.

G2C The process of learning where computers are used
at each possible step of the process: enrollment,
instruction design, content delivery, evaluation,
assessment and support.

6. Answer the following questions.

a. What do you understand by information technology? Why is it
important?

b. What are the strategies of IT Policy of Nepal?
c. List any five important IT Policy of Nepal.
d. List any five action plan that shall be adopted to implement the

information technology policy of Nepal.
e. What is e-government?
f. What are the advantages of e-Government?
g. What are the disadvantages of e-Government?
h. What are the main domains of e-Government?
i. What are the four types of e-Government services?
j. What is Government-to-Citizen (G2C)? What does it include?
k. What is Government-to-Government (G2G)? What does it include?

JBD
106 Computer Studies-9

Chapter 10

INTRODUCTION
TO

OPERATING
SYSTEM

Objectives

After completing this chapter, you will be able to:
y Describe the role of an operating system.
y Explain the different types of operating system.
y Explain the MS-DOS boot process and the role of config.sys and autoexec.bat files.
y Identify and compare the two types of MS-DOS command.
y Explain how to manage files and folders in Windows 7.

C Ooncept verview

An operating system is considered as the backbone of a computer, managing
both software and hardware resources. It is comprised of system software, or
the fundamental files your computer needs to boot up and function. Every
desktop computer, tablet, and smartphone includes an operating system that
provides basic functionality for the device. Operating systems are responsible
for everything from the control and allocation of memory to recognizing input
from external devices and transmitting output to computer displays. They also
manage files on computer hard drives and control peripherals, like printers and
scanners. Without it, the system cannot function. There is a close relationship
between the power of computer hardware and the power of its operating system.
The faster and more powerful the CPU and the greater the amount of memory,
the more the operating system can do. The more the operating system can do,
the more useful it can make a computer for its users. The most popular operating
systems include MS-DOS, Windows 7, Windows 8, Mac OS and Linux.

JBD
Computer Studies-9 107

Functions of Operating System
The operating system performs a variety of important tasks.
• Manages the allocation of main memory to specific jobs.
• Manages the input to and output from a computer system.
• Easy interaction between users and computer.
• Assigns processors to different tasks being performed by the computer

system.
• Monitors the status of critical computer components to detect failures that

affect processing.
• Providing security to users’ jobs and files.
• Manages the storage and retrieval of data from disks.

Types of Operating System
There are generally four types of operating system based on the types of computers
they control and the sort of applications they support. The categories are:

Real-time operating system (RTOS)
Real-time operating systems are used to control machinery, scientific instruments
and industrial systems. RTOS typically has very little user-interface capability,
and no end-user utilities, since the system will be a “sealed box” when delivered
for use. A very important part of an RTOS is managing the resources of the
computer so that a particular operation executes in precisely the same amount of
time, every time it occurs.

Single-user, single task
Single-user, single tasking operating system is designed to manage the computer
so that one user can effectively do one thing at a time. The Palm OS for Palm
handheld computer is a good example of a modern single-user, single-task
operating system.

Single-user, multi-tasking
Single-user, multi-tasking is the type of operating system most people use on their
desktop and laptop computers today. It is capable of running multiple programs
at the same time on a single computer. Microsoft’s Windows and Apple’s MacOS
platforms are the examples of single-user, multi-tasking operating systems.

JBD
108 Computer Studies-9

Multi-user
Multi-user operating system allows many different users to take advantage of the
computer’s resources simultaneously. The operating system must make sure that
the requirements of the various users are balanced, and that each of the programs
they are using has sufficient and separate resources so that a problem with one
user doesn’t affect the entire community of users. Unix, VMS and mainframe
operating systems, such as MVS, are examples of multi-user operating systems.

User Interface
User interface is a program that controls a display for the user and allows the
user to interact with the system. A good user interface makes a computer easy to
use. Through the user interface, the computer accepts your input and presents
you with output. The most common types of user interfaces are character user
interface (CUI) and graphical user interface (GUI).

Character User Interface
Character User Interface (CUI) is
a mechanism for interacting with
a computer operating system or
software by typing commands
to perform specific tasks. The
method of instructing a computer
to perform a given task is referred
to as “entering” a command:
the system waits for the user to
conclude the submitting of the text
command by pressing the “Enter”
key. MS-DOS is a character user
interface operating system.

Graphical User Interface
Graphical User Interface (GUI) is
an interface for issuing commands
to a computer utilizing a pointing
device, such as a mouse, that
manipulates and activates
graphical images on a monitor.
Microsoft Windows is a Graphical
User Interface operating system.

JBD
Computer Studies-9 109

Microsoft Disk Operating System
MS-DOS is an acronym that stands for Microsoft Disk Operating System. It is a
single-user, single tasking operating system. It was developed for the IBM range
of computers at Microsoft Inc, USA. MS-DOS development originally started in
1981, and was first released in 1982 as MS-DOS 1.0. MS-DOS, like other operating
systems, oversees operations such as disk input and output, video support,
keyboard control, and many internal functions related to program execution and
file maintenance.
The main features of MS-DOS are:
• Interpret your keyboard and mouse input
• Display information on the monitor
• Store and retrieve information from the disk drive
• Control a printer
• Work with other hardware attached to the computer

Booting a System
Booting is a bootstrapping process that starts operating systems when the user
turns on a computer system. A boot sequence is the initial set of operations that
the computer performs when power is switched on. The bootloader typically
loads the main operating system for the computer. Once the operating system is
loaded, it is ready for users to run applications.
The main files necessary to start up a computer are:

IO.SYS
IO.SYS is an essential part of MS-DOS and Window drivers (hardware interfacing
routines) and the DOS initialization program.

MSDOS.SYS
MSDOS.SYS is an important system file on MS-DOS and Windows 9x systems. It
is executed after IO.SYS. It contains the core operating system code, the kernel.
By default the file is located in the root directory of the bootable drive/partition
(normally C:\) and has the hidden, read-only and system file attributes set.

COMMAND.COM
COMMAND.COM is the filename of the default operating system shell for DOS
operating systems and the default command line interpreter on Windows 95,
Windows 98 and Windows ME. It has an additional role as the first program
run after boot, hence being responsible for setting up the system by running the
AUTOEXEC.BAT configuration file, and being the ancestor of all processes.

JBD
110 Computer Studies-9

Types of Booting
The computer can be booted in one of the two ways:
i. Cold booting
Booting a system by switching on the power, the computer reads its RAM space

and searches for the DOS system files from the disk drives. As soon as it finds
the system files, the DOS system files are loaded from the secondary media
into the computers’ main memory. This is known as cold booting.

ii. Warm booting
Booting a system by pressing CTRL+ALT+DEL key at the same time. The

program in RAM gets deleted, searches for DOS system files and loads the
system files into the main memory of the computer. This is known as warm
booting.

MS-DOS Boot Process
When you turn on your computer, chances are that the operating system has
been setup to boot (load into RAM) automatically in this sequence:
• As soon as the computer is turned on, the basic input-output system (BIOS)

on your system’s read-only memory (ROM) chip is “woken up” and takes
charge. BIOS is built-in to the ROM chip and, unlike Random Access Memory
(RAM), ROM contents don’t get erased when the computer is turned off.
• BIOS first does a power-on self test (POST) to make sure all the computer’s
components are operational. Then the BIOS’s boot program looks for the
special boot programs that will actually load the operating system onto the
hard disk.
• First, it looks on drive A at a specific place where operating system boot files
are located. If there is a non-bootable diskette in drive A, BIOS will send you a
message that drive A does not contain a system disk. If there is no diskette in
drive A, BIOS looks for the system files at a specific place on your hard drive.
• Having identified the drive where boot files are located, BIOS next looks at
the first sector (a 512-byte area) and copies information from it into specific
locations in RAM. This information is known as the boot record or Master
Boot Record.
• It then loads the boot record into a specific place (hexadecimal address 7C00)
in RAM.

• The boot record contains a program that BIOS now branches to, giving the
boot record control of the computer.

• The boot record loads the initial system file (for example, for DOS systems,
IO.SYS) into RAM from the diskette or hard disk.

JBD
Computer Studies-9 111

• The initial file (for example, IO.SYS, which includes a program called SYSINIT)
then loads the rest of the operating system into RAM. (At this point, the boot
record is no longer needed and can be overlaid by other data.)

• The initial file (for example, SYSINIT) loads a system file (for example,
MSDOS.SYS) that knows how to work with the BIOS.

• One of the first operating system files that is loaded is a system configuration
file (for DOS, it’s called CONFIG.SYS). Information in the configuration file
tells the loading program which specific operating system files need to be
loaded (for example, specific device driver).

• Another special file that is loaded is one that tells which specific applications
or commands the user wants to have included or performed as part of the
boot process. In DOS, this file is named AUTOEXEC.BAT. In Windows, it is
called WIN.INI.

• After all operating system files have been loaded, the operating system is
given control of the computer and performs requested initial commands and
then waits for the first interactive user input.

Directory
A directory is a catalog for files stored on the disk of a personal computer. It is
used to organize your data by grouping related files in one area of your disk. It
contains the name of the file, the size of the file, date and time of file creation or
modification. There are two types of directories:

Root directory
A root directory is the top-level directory on a disk. It is created automatically
when you format a disk and start storing files on it.

Sub-directory
A sub-directory is a directory within another directory. The directory that contains
sub-directories is called a parent directory.
The rules for writing the directory names are:

• Directory name must not exceed eight characters.

• The extension can be up to three characters. They generally do not have an
extension for simplicity.

• Blank spaces are not allowed.

• Both the uppercase and lowercase letters are accepted.

JBD
112 Computer Studies-9

File

A file is a collection of logically related information. It may be a program, a
document, a database or some other collection of bytes. Each file must have its
own unique name. This name has two parts: a filename and an extension.
• Filename is the identifier of a file on a disk.
• Extension is a set of characters added to a filename that serves to extend or

clarify its meaning or to identify a file as a member of a category.
The rules that govern filenames in DOS are discussed below:
• Filenames can have a maximum of eight characters from A to Z or 1-9 or

special characters such as $ & # @ ! % ‘ ( ) - { } _ ~
• Filenames should not contain any blank character (space) and any of the

following characters: ? / \ [ ] ÷ : | < > =
• Each extension can contain a maximum of three characters.
• Files with extensions .EXE, .COM, and .BAT are called executable files and

should be used only for a very specific purpose.
• DOS reserves a few names: CON, COM1-4, LPT1-4, PRN, AUX, NUL.

DOS Special Files

There are two special files (config.sys and autoexec.bat) which have special
meanings to DOS. They will help you take greater advantage of the operating
system as you run commands and application programs, and as you use devices.
In addition to taking greater advantage of the operating system, these special
files save your time by doing tasks for you each time you start MS-DOS.

Configuration File (Config.sys)

CONFIG.SYS is a configuration file made up of DOS commands that DOS looks
for in the root directory upon startup. It is used to load drivers and change system
settings. Adding a new peripheral to a DOS computer usually requires installing
the driver program to make it operate. The install program that comes with the
peripheral often does this for you by copying the driver to your hard disk and
modifying the CONFIG.SYS file to activate it upon startup.

Manual changes to CONFIG.SYS are done with a text editor such as the DOS

Edit and the Windows Notepad utilities. To use the DOS Edit program to edit the

CONFIG.SYS file, type:

cd \ switch to root directory

edit config.sys open CONFIG.SYS for editing

To quit after making changes,

Press Alt F, then X and Enter.

JBD
Computer Studies-9 113

Automatically Execute Batch File (Autoexec.bat)
AUTOEXEC.BAT is a special DOS batch file that is automatically executed
whenever the computer is started or restarted. It must be stored in the root
directory. It is used to load TSR (Terminate and Stay Resident) programs that
stay in memory and “pop up” whenever you call them. It is also used to start
an application when the computer is turned on, perhaps a menu program that
launches a variety of applications.
Manual changes to AUTOEXEC.BAT are done with a text editor such as the DOS
Edit and the Windows Notepad utilities. To use the DOS Edit program to edit the
AUTOEXEC.BAT file, type:
cd \ switch to root directory
edit autoexec.bat open AUTOEXEC.BAT for editing
To quit DOS Edit after making the changes you required, press Alt F, then X and
Enter.
Example:
prompt $p$g
path c:\data;d:\words;e:\budget c:\dos\doskey

Path
Path is the route to a file on a disk. The path starts from the root directory. To get
to a particular file, you must trace the path from the root directory to the sub-
directory or the sub-sub-directory and so on, that contains the file.
A pathname is a sequence of directory names followed by a filename. Each
directory name is separated by a backslash ( \ ). The general format of a pathname
is as follows:
[\directoryname] [\directoryname...] \filename.

Wildcard Characters
Wildcard characters are the special characters that can be used to represent any
character or series of characters in a statement. The wildcard characters are used
to restrict the scope of a DOS command to only those files which match the pattern
specified. There are two types of wildcard characters:



i. Asterisk (*) wildcard
The asterisk (*) wildcard is used to substitute a set of characters.
For example:
C:\>DIR book.* ~ lists all the filenames having their primary name as book.

JBD
114 Computer Studies-9

ii. Question mark (?) wildcard

The question mark (?) wildcard is used to substitute a single character at a
particular position.

For example:

C:\>DIR C?????.EXE ~ lists all the files having 6 characters long with the first
character as C and the extension as EXE.

Command

Command is an instruction to a computer program that, when issued by the user,
causes an action to be carried out. Commands are usually either keywords typed
at the keyboard or choosen from a menu. MS-DOS command can have up to three
parts- a command name, parameter and switch. All the MS-DOS commands have
command names. MS-DOS command uses the following syntax:

COMMAND [option]

Command is an MS-DOS command, and [option] may include drive:, path,
filename, pathname and switch. The entire set of commands available in DOS
can be divided into two types. These are:

Internal commands

The commands that COMMAND.COM recognizes are called internal commands.
These commands reside in memory as long as the machine is at the system prompt
(C:\>) level. Some of the MS-DOS internal commands are listed below:

CHDIR (CD) CLS COPY

DATE DEL DIR

MKDIR (MD) PATH PROMPT

REN RMDIR TIME

TYPE VER VOL

External commands

The commands that are stored on the system disk as program files are called

external commands. They must be read from the disk before they are executed.

Any filename with an extension of .COM, .EXE, or .BAT is considered as an

external command. Some of the MS-DOS external commands are listed below:

ATTRIB BACKUP CHKDSK

DISKCOMP DISKCOPY FORMAT

LABEL MORE SYS

TREE XCOPY

JBD
Computer Studies-9 115

Date Command
Date command is used to display or set the system date. The syntax is:
DATE <mm-dd-yy>
Where,
mm Indicates month (1-12)
dd Indicates day (1-31)
yy Indicates year (1980-2079)
Example:
C:\>DATE 02-04-2015
Sets the new date to 02-04-2015.

Time Command
Time command allows you to enter or change the time known to the system. The
syntax is:
TIME hh:mm [:ss] [:cc] [a|p]
Where,
hh Specifies the hour (0 through 23).
mm Specifies the minutes (0 through 59).
ss Specifies the seconds (0 through 59).
cc Specifies the hundredth of a second
(0 through 99).
A/P Specifies AM or PM.
Example:
C:\>TIME 12:00P
Sets the system time to 12:00 P.M.

Type Command

Type command displays the contents of a text file on the screen. The syntax
is:

TYPE [drive:] [path] filename

Where, Specifies drive name that contains the file.
drive:

path Route to a file you want to display.

filename Specifies the name of the file whose content is to be displayed.

Example:

C:\>TYPE AUTOEXEC.BAT

Allows you to view the content of a file AUTOEXEC.BAT on the monitor.

JBD
116 Computer Studies-9

Ren (Rename) Command

Ren (Rename) command allows you to rename a file or group of files. The

syntax is:

RENAME [drive:][path][old filename][new filename]

or

REN [drive:][path][old filename] [new filename]

Where,

[drive:] path Specifies the location of file to rename.

old filename Specifies the name of file to be renamed.

new filename Specifies the new name for the file.

Example:

C:\>REN *.COM *.EXE

Renames all the files having the extension .COM into the extension .EXE, with the
same corresponding primary names.

Copy Command

Copy command copies one or more files to another location. This command also
appends files. The syntax is:

To copy files

COPY [drive:] [source] [drive:] [destination]

Where,

drive: Specifies the name of drive.

source Specifies the file or files to be copied.

destination Specifies the directory and/or filename for the new file(s).

To append files

COPY pathname1+pathname2 [...] pathname n

Example:

C:\>COPY STORY.TXT B:

Copies the file STORY.TXT from drive C: to drive B:

Del (Erase) Command
Del (Erase) command allows to delete one or more unwanted files. The syntax
is:
DEL [drive:][path]filename [/p]
or
ERASE [drive:][path]filename [/p]

JBD
Computer Studies-9 117

Where,

drive Specifies the name of drive containing the file to be deleted.

path Specifies the location of the file.

filename Specifies the name of the file to be deleted.

/p Prompts for confirmation before deleting each file.

Examples:

C:\>DEL *.EXE

Deletes a group of file ending with an extension EXE from drive C:.

C:\>DEL B????.TXT

Deletes all the files having 5 characters long with the first character as B and the
extension is TXT.

C:\>DEL STORY??.TXT

Deletes all the files whose name is 7 characters wide starting with STORY having
TXT as an extension.

C:\STORY>DEL *.TXT

Deletes all the files of subdirectory STORY of drive C: with an extension
TXT.

Edit Command

Edit command starts the MS-DOS editor, a text editor used to create and edit
ASCII text files. The syntax is:

EDIT [/b] [/h] [/r] [/s] [/<nnn>] [/?] [file(s)]

Where,

/B Forces monochrome mode.

/H Displays the maximum number of lines possible for your
hardware.

/R Load file(s) in read-only mode.

/S Forces the use of short filenames.

/<nnn> Load binary file(s), wrapping lines to <nnn> characters wide.

/? Displays the help screen.

[file] Specifies initial files(s) to load. Wildcards and multiple
filespecs can be given.

Example:

C:\>EDIT AUTOEXEC.BAT

Starts the MS-DOS editor and allows to edit text file named AUTOEXEC.BAT.

JBD
118 Computer Studies-9

Format Command

Format command formats the disk in the specified drive to accept MS-DOS files.
The syntax is:

FORMAT drive:[/v[:label]] [/q][/s][/f:size]

Where,

/v[: label] Specifies the volume label.

/q Performs a quick format.

/f:size Specifies the size of the floppy disk to format (such as 160K, 180K,
320K, 360K, 720K, 1.2MB, 1.44MB, 2.88MB).

/S Copies system files to the formatted disk.

Examples:

C:\>FORMAT A:

Formats a disk in drive A:

C:\>FORMAT A:/S

Formats a disk in drive A: and copies the system files on to it.

C:/>FORMAT A:/V:ROJA

Formats a disk in drive A: and assigns the volume label ROJA.

Md (Mkdir) Command

Md (Mkdir) command allows you to create new subdirectories. The syntax
is:

MD [drive:] path

or

MKDIR [drive:] path

Where,

drive Specifies the name of drive where the directory is to be created.

path Specifies the location for the new subdirectory.

Example:

C:\>MD BOOKS

Creates a new subdirectory called BOOKS on drive C:

Cd (Chdir) Command
Cd (Chdir) command displays working (current) directory and / or changes to a
different directory. The syntax is:
CHDIR [drive:] [path]

JBD
Computer Studies-9 119

or
CD [drive:][path]
CHDIR [..] or CD [..]
CHDIR [\] or CD [\]
Where,
.. Specifies that you want to change to the parent directory.
\ Specifies that you want to change to the root directory.
Examples:
C:\>CD BOOKS
Changes to a subdirectory called BOOKS of drive C:
C:\BOOKS\SALES>CD..
Changes the current directory to the preceding level of the directory.

Rd (Rmdir) Command

Rd (Rmdir) removes an existing subdirectory from a disk. The directory to be
removed must be empty. The syntax is:

RD [drive:] path

or

RMDIR [drive:] path

Where,

drive Specifies a drive from which the directory will be deleted.

path Specifies the location of a directory to be deleted.

Examples:

C:\>RD BOOKS

Removes a subdirectory called BOOKS from drive C:

C:\>RD BOOKS\SALES

Removes subdirectory SALES from the parent directory BOOKS.

Dir Command

Dir command displays list of files and subdirectories stored on the disk. The
syntax is:

DIR [drive:][path][filename][/p][/w] [/a[[:]attributes]][/o[[:] sortorder]] [s] [/b]
[/l]

Where,

[drive:] [path] [filename] Specifies drive, directory, and/or files to list.

JBD
120 Computer Studies-9

/P Pauses after each screenful of information.

/W Uses wide list format.

/A attributes:

D Directories

R Read-only files

H Hidden files

A Files ready for archiving

S System files

- Prefix meaning not

/O List by files in sorted order, sortorder:

N By name (alphabetic)

S By size (smallest first)

E By extension (alphabetic)

D By date & time (earliest first)

G Group directories first

- Prefix to reverse order

A By Last Access Date (earliest first)

/S Display files in specified directory and all subdirectories.

/B Uses bare format (no heading information or summary).

/L Uses lowercase.

Examples:
C:\>DIR/P
Displays all the files and directories in page-wise of drive C:.
C:\>DIR/W
Displays all the files and directories in a wide list format.

Vol Command
Vol command displays the disk volume label and serial number, if they exist.
The syntax is:
VOL [drive:]
Where,
drive : Specifies the drive whose volume label and serial number you want

to see.
Examples:
C:\>VOL
Displays the volume label and serial number of drive C:.
C:\>VOL B:
Display the volume label and serial number of drive B:.

JBD
Computer Studies-9 121

Microsoft Windows 7
Microsoft Windows 7 is the most widely used operating system for desktop and
laptop computers. It is a GUI-style operating system produced by US-based
Microsoft, the world’s largest software company. It provides the following
advantages:
• It is easier for a new user to learn and use the computer.
• It allows the user to work

on a number of applications
simultaneously.
• It controls the different parts
of your computer system, such
as the printer and monitor,
and enables them to work
together.
• It provides ways to organize
and manage files stored on your
computer.
• It provides Graphical User
Interface (GUI).

Desktop
When you switch ON your computer having Windows as the operating system,
Windows gets loaded automatically. The display that appears on your monitor
screen is called the Windows Desktop. It is the background image of a display
screen, on which windows, icons, and other graphical items appear.
The Windows Desktop has various components as shown below:

My Documents
My Documents provides a default storage location for data files you create in
applications such as WordPad. Double-click the My Documents icon on the
desktop and then double-click the name of the file you want to open.

Computer
My Computer is a system folder that appears as an icon on the desktop. It allows
you to browse all the disks that are physically attached to your computer. The
contents of the My Computer window depend on the disk drives on your PC and
the network support that is installed. There are icons to open the Control Panel,
access the printers, and connect to other computers through dialup connections.

JBD
122 Computer Studies-9

Recycle Bin
Recycle Bin is a system folder in which Windows 7 stores
the items you delete. Windows 7 puts the deleted objects
in the Recycle Bin. These deleted files still occupy as much
disk space as they did before you delete them. The space
does not become available until you empty the Recycle Bin.
The Recycle Bin keeps track of only the files that you delete
from your local hard disk. The files that you delete from
removable media such as pen drives are not sent to the
Recycle Bin and therefore, cannot be undeleted.
The features of Recycle Bin are:
• Double-click the Recycle Bin icon on the desktop to view its contents.
• Items you drag onto the Recycle Bin icon are stored there until you remove

them or until they take up a specified percentage of available hard disk
space.
• Pressing Delete key also places deleted item in the Recycle Bin.
• You can restore all, or just selected items in the Recycle Bin to their original
folder locations.
• You can empty all or selected items in the Recycle Bin.

Taskbar
Taskbar is a long horizontal bar located at the bottom of the screen when you start
Windows for the first time. The taskbar contains three elements: the Start menu
button, buttons for open windows and the time of day indicator at the right end
of the taskbar.

Windows Dialog Box
Dialog boxes are special-purpose windows
found in a graphical user interface, such as
Windows, that provides information and
possible options to the user. It is so named
because it conducts a “dialog” with you as it
seeks the information it needs to perform a
task. Windows dialog box contains controls
that provide different ways for you to specify
a setting or choose an option. Some of the
controls of dialog box are command buttons,
radio buttons, list boxes, text boxes, and so on.

JBD
Computer Studies-9 123

Text boxes
Text box allows you to enter short strings of text data. The text box may be blank
or may contain text when the dialog box opens. To fill a text box, first click the
mouse button in the box, or press the TAB key till the text box is selected.

List boxes
List box is a control in Windows that enables the user to choose one option from a
list of possibilities. The list box appears as a box, displaying the currently selected
option, next to a button marked with a down arrow. When the user clicks the
button, the list appears. The list has a scroll bar if there are more options that the
list has room to show.

Drop-down list boxes
Drop down list box is a rectangular box with the current selection marked by the
selection cursor. Click its down arrow with the mouse to open the drop-down list
and then make a selection.

Option buttons
Option button is a small round button that enables you to select only one option
at a time. The selected option is marked by a round dark dot in a circle. It is
referred to by its label. It is also called radio button. Click a specific button to
choose it.

Check boxes
Check box is a small square box that appears in a dialog box used to enable or
disable one or more features or options from a set. Click a check box to turn a
feature on or off.

Command buttons
Command button is a small rectangular box that is used to answer a question
or acknowledge something that the computer is displaying. You will usually
be asked to click it or press a key on your keyboard to respond to a particular
button. The word or group of words displayed on the top of a button is called
a caption. A button is referred to by its caption. For example, Choosing the OK
button means that the values in the dialog box are correct and Cancel button
ignores any values that you have changed.

Tab control
Tab controls identify pages of a dialog box. The tabs are labelled, and you click
one to turn to its page. Each tab is referred to by its caption.

JBD
124 Computer Studies-9

Combo box

Combo box is a combination of a list box and a text box. The user can type text
into the text box or select text from an associated list box to go into the text box.

Spinner buttons

Spinner buttons usually contain numbers. Type a value in the box, or click the up
or down arrow (usually to the right of the box) to select a value.

Mouse Pointer and its Activities

A mouse pointer on the screen is controlled by moving the device called mouse,
which has one or more push-buttons that transmit instructions to the computer.
Depending on the location of the mouse pointer and the operation of the program
with which it is working, the area of the screen where the mouse pointer appears
serves as the target for an action when the user presses one of the mouse buttons.

• Drag – Press and hold down the left mouse button while
moving the mouse pointer. It is used for selecting
multiple text characters or to move graphic objects.

• Right click – Point to an object, then quickly press and release the
right mouse button. It opens a shortcut menu that
provides options for working with the object.

• Point – Move the mouse so the mouse pointer is positioned
on the item you want to use.

Windows Explorer to View Files

Windows Explorer is a program that helps in managing files/folders. In the
Windows Explorer window, the Folders bar (left pane) shows the hierarchy of
folders in your computer, while the right pane shows the content for the folder
selected in the left pane.

To view files using Windows Explorer, follow these steps:

• Click on the Start button to see the Start menu.

• Choose Programs|Accessories| Windows Explorer.

• On the left side of the Windows Explorer window, click the plus sign (+) to
see the folders it contains.

• Click the minus sign (-) of a folder to hide the folders.

• In Folder bar, click the desired folder to view its contents in the right pane.

JBD
Computer Studies-9 125

Creating a Folder
A folder is a location on some storage medium in which you can store files and
other folders. You can create a new folder to organize the information stored on
your computer.
To create a folder on the desktop, follow these steps:
• Right-click a blank area on your desktop. A menu
appears:
• Point to New on the shortcut menu.
• Click on Folder on the submenu.
• Type a new folder name and then press Enter key.

Creating a File
A file is a collection of related information. You can instantly create, name and
store a new file in the location you want.
To create a file on the desktop, follow these steps:
• Open the folder in which to create new file.
• Right-click an empty area of the desktop or folder.

A menu appears:
• Point to New on the shortcut menu.
• Click desired file type on the submenu. A file icon

appears with a temporary file name.
• Type new file name and then press Enter key.

Renaming Files/Folders
You can rename both files and folders. You can give the file a new name to describe
the contents. This makes it easier to find the file.
To change the file’s/folder’s name, follow these steps:
• Open folder containing file or folder to rename.
• Right-click the file/folder which you want to rename. A menu will pop up.
• Click on Rename.
• Type a new name for the file or folder.
• Press Enter key.

JBD
126 Computer Studies-9

Moving Files/Folders
You can reorganize the files stored on your computer by placing them in different
folders. Moving files is similar to rearranging documents in a filing cabinet to
make them easier to find.
To move a file to a folder, follow these steps:
• Place your mouse pointer over the file that you want to move.
• Press and hold down the left button as you drag the mouse to where you

want to place the file.
• Release the button and the file moves to the new location.

Deleting Files/Folders
Except for files deleted from removable disks, such as pen drives, Microsoft
Windows stores items you delete in the Recycle Bin, where they can be restored
to their original locations, if needed.
To delete a file or a folder, follow these steps:
• Open folder containing files or folders to delete.
• Select files or folders to delete. Windows highlight selected items.
• Drag the selection onto the Recycle Bin.

To restore deleted files, follow these steps:
• Double-click the Recycle Bin folder on the desktop. The Recycle Bin folder

opens.
• Select files or folders to restore.
• Right-click any selected icon.
• Click Restore on the shortcut menu.

JBD
Computer Studies-9 127

C Dompu- ictionary

Batch file : A file containing a list of operating system commands
to be executed in succession. Batch files are
Default drive distinguished by their “.BAT” suffix.
Desktop
Dialog boxes : The drive containing the disk. on which DOS looks
for and saves files unless otherwise specified.
File
GUI : In a GUI, the backdrop on which windows and icons
of disks and applications reside.
Recap
: A special purpose window found in a graphical user
interface, such as Windows, that provides information
and possible options to the user.

: A collection of information, such as a program, a set of
data used by a program, or a user created document.

: A visual computer environment that represents
programs, files, and options with graphical images,
such as icons, menus, and dialog boxes, on the screen.

• An operating system is the most important software that runs on a computer.

• User interface is a program that controls a display for the user and allows the
user to interact with the system.

• MS-DOS is a single-user, single tasking operating system.

• Booting is a bootstrapping process that starts operating systems when the user
turns on a computer system.

• A directory is a catalog for files stored on the disk of a personal computer.

• A file is a collection of logically related information.

• CONFIG.SYS is a configuration file made up of DOS commands that DOS
looks for in the root directory upon startup.

• AUTOEXEC.BAT is a special DOS batch file that is automatically executed
whenever the computer is started or restarted.

• Wildcard characters are the special characters that can be used to represent
any character or series of characters in a statement.

• The commands that COMMAND.COM recognizes are called internal
commands.

• The commands that are stored on the system disk as program files are called
external commands.

JBD
128 Computer Studies-9

Review Yourself

1. State whether the following statements are true or false.

a.
Operating system is considered as the backbone of a computer, managing
both software and hardware resources.

b. Graphical User Interface (GUI) is a mechanism for interacting with a
computer operating system or software by typing commands to perform
specific tasks.

c. A sub directory is the top-level directory on a disk.
d. AUTOEXEC.BAT is a configuration file made up of DOS commands that

DOS looks for in the root directory upon startup.
e. Wildcard characters are the special characters that can be used to

represent any character or series of characters in a statement.

2. Fill in the blanks.

a. _____________ is designed to manage the computer so that one user can
effectively do one thing at a time.

b. ____________ is a bootstrapping process that starts operating systems
when the user turns on a computer system.

c. The commands that are stored on the system disk as program files are
called ____________commands.

d. ____________is the background image of a display screen, on which
windows, icons, and other graphical items appear.

e. __________ are special-purpose window found in a graphical user
interface, such as Windows, that provides information and possible
options to the user.

f. _____________ is a program that helps in managing files/folders.

3. Answer the following questions.
Disk Operating System

a. What is an operating system? State any three major functions of an
operating system.

b. What are the different types of operating system? Explain each of them
in brief.

c. What is MS-DOS? List the main features of MS-DOS.
d. What is booting a system? Name the essential files required to boot a system.
e. What is a directory? What does it contain?

JBD
Computer Studies-9 129

f. What is a file? What is file made up of?
g. What is a wildcard character? What are the two wildcard characters

used in DOS? Mention their uses.
h. What is an extension? List out some typical file extensions and their

meanings.
i. What is a config.sys file? What is the role of this file in the process of

booting?
j. What is an autoexec.bat file?
k. What is a command? Distinguish between internal command and

external command.
Microsoft Windows

a. What is Microsoft Windows 7? List the advantages of Microsoft
Windows XP.

b. What is a desktop? What are the main elements of Windows desktop?
c. What are icons? Name few icons found on the upper-left corner of the desktop.
d. What is recycle bin? State any three characteristics of recycle bin.
e. What is a taskbar? List any two features of a taskbar.
f. What are dialog boxes? List some of the controls of Windows dialog boxes.
g. What is the Windows Explorer?

4. Write down the appropriate DOS command(s) to perform the following task:

a. To set the system date as 4th April 2015.
b. To copy all the files of A: drive having EXE as an extension of the

subdirectory BOOK to B: drive staying in C: drive.
c. To delete all the files whose name is 3 characters wide starting with

BOOKS and having DAT as an extension.
d. To edit text file named AUTOEXEC.BAT.
e. To format a disk in drive A: and copies the system files on to it.

5. Write the effects of the following MS-DOS commands:

a. C:\> DATE b. C:\>TIME

c. C:\>TYPE D:\BOOKS.TXT d. C:\>REN *.TXT *.DAT

e. C:\QB>COPY REV.BAS B: f. A:\>DEL A:\*.EXE

JBD
130 Computer Studies-9

Chapter 11

INTRODUCTION
TO

HTML

Objectives

After completing this chapter, you will be able to:
y Explain the various components of Web.
y Define HTML and explain the major features of HTML.
y Explain the basic structure and components of HTML documents.
y Explain the function and syntax of different HTML elements.

C Ooncept verview

The use of the World Wide Web has been
expanding at a phenomenal rate. As the Web
grows, so does its vehicle of communication-
HTML. The World Wide Web is one of the
most exciting and useful aspects of the
Internet. It is a leading information-exchange
service of the Internet. It was created by Tim
Berners-Lee and his colleagues at CERN and
introduced to the world in 1991. The Web
gives users access to a vast array of documents
that are connected to each other by means of
hypertext or hyperlinks. The World Wide
Web has gained popularity largely because
of its ease of use (point-and-click graphical
interface) and multimedia capabilities, as
well as its convenient access to other types of
Internet services.

JBD
Computer Studies-9 131

Web uses the following components:

Web Site
Web site is a set of interconnected web pages,
usually including a home page, generally
located on the same server, and prepared and
maintained as a collection of information by
a person, group, or organization. Web site
may contain any number of web pages. The
homepage is the first document that the user
sees when entering the web site, and it may be
followed by additional documents and files,
each with their own unique URL. Examples of
some common Web sites are www.yahoo.com
and www.google.com.

Web Server
Web server is a computer that delivers Web pages to browsers and other files to
applications via the HTTP protocol. It includes the hardware, operating system,
Web server software, TCP/IP protocols and site content (Web pages and other
files). Web server allows to publish Web sites, maintain network traffic and
manage user data. It also help in incorporating the network hierarchy in a Web
site. Two leading Web servers are Apache Web Server and Microsoft’s Internet
Information Server (IIS).

Web Browser
Web browser is a software application for retrieving, presenting and traversing
information resources on the World Wide Web. Information resources may
contain hyperlinks to other information resources. Each link contains the URL of
a resource to go to a specified link. When a link is clicked, the browser navigates
to the resource indicated by the link’s target URL, and the process of bringing
content to the user. The major web browsers are Windows Internet Explorer,
Mozilla Firefox, Apple Safari, Google Chrome and Opera.

Uniform Resource Locator (URL)
Uniform Resource Locator (URL) is an address that identifies a document or
resource on the World Wide Web. The address contains three elements: the type
of protocol used to access the file (e.g., HTTP for a Web page, ftp for an FTP
site); the domain name or IP address of the server where the file resides; and,
optionally, the pathname to the file (i.e., description of the file’s location).

JBD
132 Computer Studies-9

Hypertext Markup Language (HTML)
Hypertext Markup Language (HTML) is an authoring tool that is used in creating
Internet Web pages. It is a versatile language and can be used on any platform
or desktop. It was invented in 1990 by Tim Berners Lee, a scientist at CERN,
Switzerland, at the European Laboratory for Particle Physics. He laid down the
foundation of the World Wide Web.

The most important features of HTML are:
• It provides tags that help in changing the appearance of Web page.
• It allows images to be included on a Web page.
• It provides special tags that help text in the form of tables.
• It provides hyperlinks to connect different Web pages with one another.
• It uses style sheets to create documents that can be maintained and reused

easily.
• It is designed to work on a wide variety of platform.

HTML Tag
HTML tag is an instruction that identifies the logical text document parts-i.e. the
major structural components in a document. Tags start with a less-than sign (<)
followed by a keyword, and conclude with a greater-than sign (>). There are two
types of tags: Start tags are used to begin an effect, and end tags are used to end
that effect. End tags always repeat the keyword with a slash in front. <head>, <I>
and<font> are some of the examples of HTML tags.

HTML Element
HTML element is a fundamental component of the structure of an HTML text
document. It comprises of three parts: a start tag, the content, and an end tag.
HTML elements can be categorized as:

Element

<H1>HeadingStyleOne</H1>

Start Tag End Tag Content
Container elements
The container elements are used in pair and have starting and ending tags. These
elements define how the matter contained within them should be formatted. The
syntax for container element is:

JBD
Computer Studies-9 133

<TAG>....</TAG>
For example,
BODY is a container element. It has an opening tag (<BODY>) and a closing
element (</BODY>).

Empty elements
The empty elements do not have closing tags. These elements are stand-alone
elements and do not contain anything. The syntax for empty element is:
<TAG>
For example,
<BR> is an empty element and is used to insert a line break in the document.

Structure of an HTML
Every HTML page should contain certain standard HTML tags. There are three
tags required for every HTML page. They are HTML, HEAD and BODY. These
are the building blocks of any HTML document and are used in an orderly
manner, nested one tag inside another.
The basic structure of the HTML document is shown below:
<HTML>
<HEAD>
<TITLE>
Title of the Web page is written here
</TITLE>
</HEAD>
<BODY>
Text and graphics of the Web page is written here
</BODY>
</HTML>
The elements used in the basic structure are:

HTML element
The HTML is a container element that states that the document is an HTML type
document. A basic HTML document consists of opening (<HTML>) and closing
(</HTML>) tags. All the content of the Web page is contained within these two
tags. The syntax for HTML element is:
<HTML>
The document is included here
</HTML>

JBD
134 Computer Studies-9

HEAD element
The HTML document has a pair of opening tag <HEAD> and closing tag </
HEAD>. The HEAD element marks the position of the head section. The head
section contains elements that define certain information about an HTML
document, such as what its title is and reference information about the document.
The <HEAD> tag contains the <TITLE> tag. The <TITLE> tag specifies the title of
the HTML document. The syntax is:
<HEAD>
<TITLE>
The title is included here
</TITLE>
</HEAD>

BODY element
The BODY element includes the entire content of the document. It is opened and
closed by the <BODY> and </BODY> tags. The text and images of the document
to be displayed by the Web browser should be placed within these two tags. The
syntax is:
<BODY>
The body is included here
</BODY>
The following table displays the attributes used with the BODY element.

Attribute Description

BACKGROUND It is used to point to an image file that will be tiled across
the browser window, providing a background for the
BGCOLOR document.

TEXT It allows setting of the background colour for the
document.
LEFTMARGIN
TOPMARGIN It is used to set the foreground, or text colour of the
LINK page.
VLINK
It allows to set the left-hand margin.
ALINK
It allows to set the top-margin of the document.

It specifies the colour used for hypertext links.

It specifies the colour used for hypertext links that have
been previously visited by the viewer.

It defines the colour of the link as it is being clicked.

JBD
Computer Studies-9 135

Creating and Retrieving HTML file
HTML documents are created as plain-text files because they are written in simple
ASCII. They can be created in any text editor such as WordPad or Notepad. And
the file should be saved with an extension either .HTM or .HTML.
To start Notepad, follow these steps:
• Click on the Start menu.
• Click on Programs and then choose Accessories.
• Choose Notepad.
• Type in the HTML code.

Solved Examples

<HTML>

<BODY>

Children need discipline, limits and guidance. The best discipline leads to
children learning self-discipline.

</BODY>

</HTML>

• Choose Save As command from the File menu. Double click on My Computer
and then the name of the hard drive where you want to save your file. Create
a new folder using the Create New Folder button and then double-click on
the new folder to open it.

• Type first.htm in the File name box and click on Save.
• Open the browser (Internet Explorer), and click on File and choose Open.
• In the Open dialog box, click Browse.
• Go to the folder in which you have saved the file and double-click on the first.

htm.

Heading Element

HEADING element briefly describes the topic of the section it introduces. There
are six levels of headings in HTML with H1 as the most important and H6 as the
least. The highest-level header format is <H1> and the lowest level is <H6>. All
the styles appear in boldface and the size of the heading depends on the level
chosen, i.e. <H1> to <H6>. The headings can be aligned with the ALIGN attribute,
which can be either LEFT, RIGHT, or CENTER as values for making the headings
left-aligned, right-aligned and center-aligned respectively.

JBD
136 Computer Studies-9

Syntax
<Hn align=”left”|”right”|”center”>...</Hn>
Where,
n is the level of the heading.

Solved Examples

<HTML>
<BODY>
<H1>
Parenting and Child Health
</H1>
<H2> Discipline</H2>
Children need discipline, limits and guidance. They need to feel safe and secure
while learning to get along with others and learning to live in society.
</BODY>
</HTML>

Paragraph Element

PARAGRAPH element indicates the start of a paragraph. Typically, paragraphs
are surrounded by a vertical space of one line or half a line. It uses (<P>...</P>)
tags to separate text into different paragraphs. The paragraph can be aligned left,
right, center and justify by using the ALIGN attribute. The default horizontal
alignment is the left alignment.
Syntax
<P align=”left”| “right”|”center” |”justify” > ...
</P>

Solved Examples

<HTML>

<BODY>

<H1> Discipline </H1>

<P>

Children need discipline, limits and guidance. They need to feel safe and secure
while learning to get along with others and learning to live in society. The best
discipline leads to children learning self-discipline.

</P>

</BODY>

</HTML>

JBD
Computer Studies-9 137

Line Break Element
LINE BREAK element is an empty element that moves any text following it to the
next text. It uses (<BR>) tag.
Syntax
<BR>

Solved Examples
<HTML>
<BODY>
<CENTER> Famous Proverbs <BR>
a. A book is like a garden carried in the pocket. <BR>
b. A bird in the hand is worth two in a bush. <BR>
c. A close friend can become a close enemy.<BR>
d. A drowning man is not troubled by rain.<BR>
e. A friend in need is a friend indeed.
</CENTER>
</BODY>
</HTML>

Center Element

The CENTER element uses (<CENTER> ... </CENTER>) tags to center the content
between the current left and right margins. It is used to center a whole document
and it can also be used to center tables.
Syntax
<CENTER>...</CENTER>

Solved Examples

<HTML>

<BODY>

<CENTER>

Children need discipline, limits and guidance. They need to feel safe and secure
while learning to get along with others and learning to live in society.

</CENTER>

</BODY>

</HTML>

JBD
138 Computer Studies-9

Horizontal Rule Element

HORIZONTAL RULE element is a divider between sections of text such as a
full width horizontal rule or an equivalent graphic display. The default rule is a
shaded, engraved line. It uses <HR> tag to draw a horizontal line across the page.

Syntax
<HR
align = “left”|”right”|”center”
noshade
color=”colour name”
size=”pixels”
width=”pi xels or percentage” >

Attribute Description

SIZE It defines the thickness of the horizontal line in pixels.
The default is 2 pixels. For example, <HR SIZE=10>
will display a rule with the thickness of 10 pixels.

WIDTH It defines the horizontal width of the line. The default is
the width of the page. It can have a numeric value or a
percentage value. For example,<HR WIDTH=50%>will
display the horizontal rule with a width that is 50% of
the page width.

ALIGN It specifies the horizontal alignment of lines. The
alignment of the rule can be set to left, right, or center.

NOSHADE It displays a solid black line that has no shading.

COLOR It is used to specify the colour of a horizontal rule.

Font-style Elements
All the font-style elements are container elements. They are used to change the
appearance of text. They can be nested according to the normal rules of nesting
text-level elements. Some of the font-style elements are listed below:

Element Description

<B> It is used to change the text into bold characters.
<I>
<U> It is used to italicizes the text characters.
<SUP>
<SUB> It is used to underline the written text.
<STRIKE> It is used to convert text into superscript, as in (a+b)2.

It is used to convert text into subscript, as in H2O.
It indicates that the enclosed text should have a line drawn
through the middle of the text.

JBD
Computer Studies-9 139

Solved Examples
<HTML>
<BODY>
A <B>penny</B> saved is a penny gained. <BR>
A <I> teacher </I> is better than two books. <BR>
An <U>apple</U> a day keeps the doctor away.<BR>
(a+b)<SUP>2</SUP>=a<SUP>2</SUP>
+2ab+b<SUP>2</SUP> <BR>
H<SUB>2</SUB>SO<SUB>4</SUB>
</BODY>
</HTML>

Font Element
The FONT element uses the (<FONT> and </FONT>) tags to change the size,
typeface, and colour of the font.
Syntax
<FONT
size=value
color=”colour name”
face=”font name”>...</FONT>

Attribute Description
SIZE
It is used to set the absolute or relative values ranging from
1 (smallest) to 7 (largest). The default size is 3.

For example:

COLOR <FONT SIZE=”+5”> JAY </FONT>

will make the font size five steps bigger than the current
size.
FACE
It is used to change the colour of the text that will appear on
the screen. It can be set with an RGB value or a colour name
supported by the browser.

For example:

<FONT COLOR = “Red”> JAY</FONT>

It is used to specify the typeface for the text. If no match is
found, the text is displayed in the default type according
to the browser preference settings. It is possible to specify
a comma-delimited list of fonts to try one by one before
defaulting to the normal proportional or fixed width font.

JBD
140 Computer Studies-9

Solved Examples

<HTML>

<BODY>

<FONT SIZE=4 COLOR=”Red”>

Once upon a time there was an old woman who loved baking gingerbread.
She would bake gingerbread cookies, cakes, houses and gingerbread people,
all decorated with chocolate and peppermint, caramel candies and colored
frosting. She lived with her husband on a farm at the edge of town. The sweet
spicy smell of gingerbread brought children skipping and running to see what
would be offered that day. Unfortunately the children gobbled up the treats so
fast that the old woman had a hard time keeping her supply of flour and spices
to continue making the batches of gingerbread. Sometimes she suspected little
hands of having reached through her kitchen window because gingerbread
pieces and cookies would disappear. One time a whole gingerbread house
vanished mysteriously.

</FONT>

</BODY>

</HTML>

Marquee Element

MARQUEE ELEMENT uses <MARQUEE> ...</MARQUEE> creates a region on a
page that displays a horizontal scrolling text message. It highlights the scrolling
text.

Syntax
<MARQUEE
behavior=”scroll”|” slide”|”alternate”
direction=”left”|”right”|”up”|”down”
bgcolor=”colour name or an RGB value” scrolldelay=time in milliseconds>
...
</MARQUEE>

Attribute Description
ALIGN
It is used to specify the vertical alignment of the marquee
BEHAVIOR text. This attribute can be set to TOP, MIDDLE, or BOTTOM.

It is used to set the movement of the marquee. This can be
set to SCROLL, SLIDE and ALTERNATE.

JBD
Computer Studies-9 141

Attribute Description

BGCOLOR It is used to set a background colour for the marquee with a
colour name or an RGB value.

DIRECTION It is used to specify the direction in which the text will scroll.
The default direction is LEFT. The text can be made to scroll
from the left to right by setting the direction to RIGHT.

SCROLL DELAY It is used to set an amount of time (in milliseconds) between
each successive scrolling of the marquee text.

SCROLL It is used to specify the number of pixels between each
AMOUNT successive draw of the marquee text.

LOOP It is used to set the number of times a marquee will loop
when activated. If n = -1 or LOOP = INFINITE is specified,
then the marquee will loop infinitely.

HSPACE and It is used to set the number of pixels of horizontal and vertical

VSPACE space around the marquee.

HEIGHT and It is used to set the vertical and horizontal size of the marquee

WIDTH in pixels or as a percentage of the window.

List Elements
List elements are a great way to provide information in a structured, easy to read-
to-read format. These elements may be nested within another set of elements.
HTML offers authors several mechanisms for specifying lists of information.
All lists must contain one or more list elements. Lists may contain unordered
information and ordered information.

Ordered List
The ordered list is used when the items are to be placed in a specific order. It
displays the list that is preceded by Arabic numbers or letters or Roman numerals.
The ordered list must begin with <OL> tag and must end with </OL> tag. Each
list items start with the tag <LI>.

Syntax
<OL start = “value” type = “A”|”a”|”I”|”i”|”1”> ..... </OL>

JBD
142 Computer Studies-9

Attribute Description
TYPE
It is used to define the type of numbering sequence used for
START each list item.
It is used to indicate the starting number for the list. Arabic
numbers are the default.

Solved Examples

<HTML>

<BODY>

<UL TYPE=”DISC”>

<LI> Between the devil and the deep blue sea.

<LI>Beware of a silent dog and still water.

<LI> Evil is sooner believed than good.

</UL>

</BODY>

</HTML>

Image Element
Graphics make the document look attractive and interesting. They can be linked
or inline. Linked graphics create a link to the image to be displayed whereas
inline graphics are inserted within a line of body text. There are a number of
graphics format supported by the World Wide Web browsers. The most widely
used among them are: Graphics Interchange Format (GIF) and Joint Photographic
Experts Group (JPEG).
The image element which consists of the <IMG> tag is used to include graphic
images in the body of HTML document. It is an empty element.
Syntax
< IMG
src = “image_url”
align = “top”|”middle”|”bottom”|”left”| “right”|”center”
width = “pixels”
height = “pixels”
border = “border width_value”>

JBD
Computer Studies-9 143

Attribute Description
SRC
It is used to specify the image to be inserted in the page. SRC
is a mandatory attribute.

ALIGN For example:

<IMG SRC = “PIC.JPG”>

It is used to control the vertical alignment of the text adjacent
to the image. ALIGN = TOP aligns the image to the top of
the smallest item in the line. ALIGN = MIDDLE aligns the
baseline of the current line with the middle of the images.

WIDTH ALIGN = BOTTOM aligns the bottom of the image with the
baseline of the current line.
HEIGHT
ALIGN = LEFT aligns the image with the left margin.
ALT
ALIGN = RIGHT aligns the image with the right margin.
BORDER
ALIGN=CENTER aligns the image at the center of the screen.

HSPACE For example:

VSPACE <IMG SRC= “PIC.JPG” ALIGN=TOP>

It is used to specify the width of the image in pixels.

<IMG SRC=” PIC.JPG” WIDTH=100>

It is used to specify the height of the image in pixels.

<IMG SRC= “PIC.JPG” HEIGHT=100>

It is used to specify an alternate text that can be displayed in
place of the image.

It is used to specify the size of the border to be placed around
the image.

<IMG SRC= “PIC.JPG” BORDER=5>

It is used to indicate the amount of space to the left and right
of the margin.

It is used to indicate the amount of space to the top and
bottom of the margin.

JBD
144 Computer Studies-9

Solved Examples
<HTML>

<BODY>

<UL TYPE=”DISC”>

<LI> Between the devil and the deep blue sea.

<LI>Beware of a silent dog and still water.

<LI> Evil is sooner believed than good.

</UL>

</BODY>

</HTML>

Table Element
The TABLE element defines a table for multi-dimensional data arranged in rows
and columns. Table may contain objects, such as text, images and anchor. If
this element is omitted, then the rest of the elements will be ignored. The table
element starts with the <TABLE> tag and ends with a </TABLE> tag. Any table
related elements occurring outside of these elements are ignored.
Syntax
< TABLE>
....
</TABLE>

Tag Description

<TH> The <TH> attribute stands for table header. By, default,
<TR> header cells are bold and center-aligned. Table headers
<TD> should be written within the <TH>...</TH> tags.

The <TR> attribute stands for table row. It is used to specify
a table row. The number of rows in a table depends on how
many <TR> tags are contained within the table. The contents
of a row are placed between <TR>...</TR> tags.

The <TD> attribute stands for table data. It is used to define
table data. Table data must be written within <TD> and </
TD> tags. Table data cells must appear within table rows. A
cell can contain any of the HTML elements, which are a part
of the HTML document.

JBD
Computer Studies-9 145

The TABLE element has certain attributes that let you change the colour,
alignment, and specify the border of the table. The following table displays some
of the commonly used attributes along with their descriptions.

Attribute Description

BORDER It controls the border to be placed around the table. By
default, tables are shown without borders. The size of the
border can be specified by using BORDER =value, where
value should be a pixel value.

CELLSPACING It controls the spacing between adjacent cells. The syntax
is CELLSPACING = value, where the value should be a
pixel value.

CELLPADDING It controls the distance between the data in a cell and the
boundaries of the cell. The syntax is CELLPADDING =
value, where the value should be a pixel value.

WIDTH It is used to set the width of the table to a specific number
of pixels or to a percentage of the available screen width.
The syntax for this attribute is WIDTH = <value or
percent>.

ALIGN It is used to control the horizontal alignment of the table.
The syntax is ALIGN=value. The allowed values are “left”,
“right”, or “center”.

VALIGN It is used to control the vertical alignment of the table. The
syntax is VALIGN = value.

The TABLE element has certain attributes that let you change the colour,
alignment, and specify the border of the table. The following table displays some
of the commonly used attributes along with their descriptions.

Attribute Description

BGCOLOR It is used to set the background colour of the table. The
BORDERCOLOR syntax is BGCOLOR = “colour name or colour value”.

BACKGROUND It is used to set the colour of the border of the table. The
syntax is BORDERCOLOR = “colour name or colour
value”.

It is used to place an image in the background of the
table. The image can be tiled behind all the table cells. The
syntax is either <TABLE BACKGROUND= filename>

JBD
146 Computer Studies-9

Solved Examples

<HTML>
<HEAD>

<TITLE>BOOK SHOP</TITLE>
</HEAD>
<BODY BGCOLOR=”RED”>
<TABLE BORDER=2 ALIGN=CENTER>
<CAPTION><B> BOOK LIST <B> <CAPTION>
<TR>
<TH >Serial Number
<TH >Book’s Name
<TH >Author’s Name
<TH >Cost
</TR>
<TR>
<TD>101
<TD ALIGN=CENTER>Fun with Computer
<TD ALIGN=CENTER>Bishwas
<TD ALIGN=RIGHT>Rs.2500.00
</TR>
<TR>
<TD>102
<TD ALIGN=CENTER>Computer Magic
<TD ALIGN=CENTER>Kiran Shrestha
<TD ALIGN=RIGHT>Rs.5000.00
</TR>
<TR>
<TD>103
<TD ALIGN=CENTER>Fundamentals of Computers
<TD ALIGN=CENTER>Dinesh Rai
<TD ALIGN=RIGHT>Rs.6500.00
</TR>
<TR>
<TD>104

JBD
Computer Studies-9 147

<TD ALIGN=CENTER>Learn Excel
<TD ALIGN=CENTER>Hari Poudel
<TD ALIGN=RIGHT>Rs.500.00
</TR>
<TR>
<TD>105
<TD ALIGN=CENTER>Learn BASIC
<TD ALIGN=CENTER>Rajesh Poudel
<TD ALIGN=RIGHT>Rs.5000.00
</TR>
</TABLE>
</BODY>
</HTML>

Attribute Description
HREF
It is used to specify a hypertext link to another resource,
such as an HTML document or a JPEG image.

NAME For example:

<A HREF = ”photo.htm”> PHOTO ALBUM</A>

It allow links to be able to point to a specific section within
TITLE a document.

For example:

<A NAME=”POINT1”>

<A HREF = “#POINT1”> CONTACT US</A>

It is used to briefly describe the contents of the link and
is rendered as a “tooltip” by some visual browsers. With
mailto links, some browsers use the TITLE attribute value
as a subject for the e-mail message.

For example: <AHREF = “HTTP:// WWW.YAHOO.

COM/” TITLE=”GAMES”> GAMES SECTION </A>

JBD
148 Computer Studies-9

C Dompu- ictionary

HTML : An authoring tool that is used in creating Internet Web
pages.

HTML tag : An instruction that identifies the logical text document
parts-i.e. the major structural components in a
document.

Hyperlink : A reference or navigation element in a document to
another section of the same document or to another
document that may be on a different website.

Home page : The first page in a Web site.

Web site : A set of interconnected webpages, usually including a
homepage, generally located on the same server, and
prepared and maintained as a collection of information
by a person, group, or organization.

Recap

• The World Wide Web has gained popularity largely because of its ease of use
(point-and-click graphical interface) and multimedia capabilities, as well as its
convenient access to other types of Internet services.

• The HTML instructions, along with the text to which the instructions apply,
are called HTML elements.

• Additional information supplied to an HTML tag is known as attributes of a tag.

• Container elements are paired and have a starting tag and an ending
tag.

• The empty elements do not have a closing tags.

• The basic structure of an HTML document consists of the HTML, the HEAD
and the BODY elements.

• The HTML is a container element that identifies the document as an HTML
document.

• The HEAD element is used to mark the position of the head section.

• The BODY element contains all the text and images that make up the page
together with all the HTML elements that provide the control and formatting
of the page.

• HTML supports six different levels for headings.

• The PARAGRAPH element uses <P>...</P> tags to indicate a paragraph.

• The LINE BREAK element is an empty element and has no end tag.

JBD
Computer Studies-9 149

Review Yourself

1. State whether the following statements are true or false.

a. The website is the first document that the user sees when entering the
web site, and it may be followed by additional documents and files, each
with their own unique URL.

b. Uniform Resource Locator (URL) is an address that identifies a document
or resource on the World Wide Web.

c. The body section contains elements that define certain information about
an HTML document.

d. The marquee element uses <MARQUEE>...</MARQUEE> creates a
region on a page that displays a horizontal scrolling text message.

e. The unordered list is used when the items are to be placed in a specific order.

2. Fill in the blanks.

a. ________________ is a computer that delivers Web pages to browsers
and other files to applications via the HTTP protocol.

b. A __________________ is a software application for retrieving, presenting,
and traversing information resources on the World Wide Web.

c. _________________ is an address that identifies a document or resource
on the World Wide Web.

d. _____________ is an authoring tool that is used in creating Internet Web
pages.

e. _____________________ is a set of communication standards used for
transferring information between computers on the network.

f. The ________ element allows the author to create a scrolling text marquee.

3. Match the following.

HTML A software application for retrieving, presenting, and
traversing information resources on the World Wide Web.

Web browser An address that identifies a document or resource on the
World Wide Web.

HTML tag An authoring tool that is used in creating Internet Web
pages.

URL An instruction that identifies the logical text document
parts-i.e. the major structural components in a document.

JBD
150 Computer Studies-9


Click to View FlipBook Version