PSEB 10th Class Computer Solutions Chapter 3 HTML II

Punjab State Board PSEB 10th Class Computer Book Solutions Chapter 3 HTML II Textbook Exercise Questions and Answers.

PSEB Solutions for Class 10 Computer Science Chapter 3 HTML II

Computer Guide for Class 10 PSEB HTML II Textbook Questions and Answers

1. Multiple Choice Questions

Question 1.
What is the use of Forms in HTML?
(a) To display contents of email
(b) To display animation effect
(c) To collect user’s input
(d) None of the Above
Answer:
(c) To collect user’s input

PSEB 10th Class Computer Science Solutions Chapter 3 HTML II

Question 2.
Which of the following is most commonly used HTTP methods?
(a) PRE and POST
(b) GET and SET
(c) ASK and REPLY
(d) GET and POST
Answer:
(d) GET and POST

Question 3.
Is it possible to link within the current page?
(a) Yes
(b) No
(c) Only in frames
(d) Null
Answer:

Question 4.
An html form is part of a web page that includes areas where:
(a) Information is feeded by the user
(b) And sent to the website server
(c) Both (a) and (b)
(d) None of the above
Answer:
(c) Both (a) and (b)

Question 5.
A container tag and is used to allow multiple lines of text in a single input item is known as:
(a) Text area
(b) Checkbox
(c) Radio Button
(d) None of the above
Answer:
(a) Text area

PSEB 10th Class Computer Book Chapter 3 HTML II

PSEB 10th Class Computer Science Solutions Chapter 3 HTML II

2. Fill in the Blanks

Question 1.
……………. tag is used to create a linkon a webpage.
Answer:
Anchor

Question 2.
………….is used to feed informationinto the Webserver.
Answer:
Form

Question 3.
If you want to allow multiple lines oftext ………………. is used in the form.
Answer:
Textarea

Question 4.
To select multiple options in a form we can use …………….
Answer:
Checkbox

Question 5.
To clear all options from a form we can use ……………… button.
Answer:
Reset

PSEB 10th Class Computer Science Solutions Chapter 3 HTML II

3. True or False

Question 1.
An unvisited Link is underlined and blue.
Answer:
True

Question 2.
<input type=”password”> will show asterisks in the text box.
Answer:
True

Question 3.
Selection lists are used to define the dropdown lists.
Answer:
True

4. Full Forms

1. <A>
Answer:
Anchor tag

2. HREF
Answer:
Hyperlink REFerence

3. URL
Answer:
Uniform Resource Locator

4. BGCOLOR
Answer:
Background Color

5. SRC
Answer:
Source

PSEB 10th Class Computer Science Solutions Chapter 3 HTML II

5. Very Short Answer Type Questions

Question 1.
Which tag is used to link a webpage?
Answer:
<A> Anchor Tag.

Question 2.
Which attribute is defined to specify where to send the form-data when a form is submitted?
Answer:
Action attribute.

Question 3.
This method is used to encode the feeded data by the user by using URL path and is sent to the server.
Answer:
GET method.

Question 4.
What are used to perform some action on the given webpage?
Answer:
Button.

6. Short Answer Type Questions

Question 1.
What is hyperlink?
Answer:
Hyper link is a method to connect two destinations on web pages. These destinations can be with in a webpage or it can be outside web page i.e. on another webpage.

Question 2.
What is Anchor tag? Explain with example.
Answer:
Anchor tag is the tag which is used to create a link in html document. This tag creates link within a webpage and also with another webpage. The tag uses href as compulsory attribute.
Example : Following is an example of anchor tag <a href= “www.Google.com” > Google </a>

PSEB 10th Class Computer Science Solutions Chapter 3 HTML II

Question 3.
What is a form?
Answer:
An html form is part of a web page that includes areas where readers can enter information to be sent back to website or the publishers of the web page It is a container that consists of other form elements such as text box, radio buttons ,list box etc.

Question 4.
Name diffefent types of buttons used in html form.
Answer:
Following are the types of buttons in HTML.
1. Submit Button
2. Reset Botton

Question 5.
What is checkbox?
Answer:
Check box appears as a small square the user can select or deselect by clicking on it. It is generally used where a group is used for sharing a common name from where information can be selected It is used in <input> html element. We must give each check box a name attributes the value defined in the type at¬tribute is checkbox. These Eire explained below with an example.
<input type-‘checkbox” name=”Child”>Children Toys <input type-‘checkbox” name=”Fumiture”> stool
You can check any option or both by clicking on it. It also supports some additional attributes.

7. Long Answer Type Questions

Question 1.
Discuss different types of buttons with example. .
Answer:
Buttons are used to perform some action on the given webpage. Some important buttons are discussed below :
Submit button:
Every form must include a button that submits the form data to the server. You can put any label you like on this button. It has two attributes these are type, which has submit value and value attribute defines the name of the • submit button which can be displayed on the button. These are explained below with an example:
Ex.:<input type=”submit” value=”OK”>
A button will appear on screen. When the user clicks it, all data items on the form are submitted

Reset Button:
You can also include a button that clears all entries on the form so users can start over if they change their minds or make mistakes. It has two attributes these are “type”, which has reset value and value attribute defines the name of the reset button, which can be displayed on the button. These are explained below with an example:
Ex.:<input type= “reset”value= “Reset”>

PSEB 10th Class Computer Science Solutions Chapter 3 HTML II

Question 2.
What is selection list in form?
Answer:
Selection list is an option in which user can select single or multiple options from a given list. In this option multiple inputs are available but some options can be displayed at a time. Scrolling Lists and Pull-Down pick lists are created with the<select>tag. You can use this tag together with the<option>tag: <select>
<option> wjndows</option><option> Linux </option><option> Mac</option>
</select>
No html tags other than <option> and </option> should appear between the <select> and </select> tags.
Attributes of select tag:
Select tag has following attributes-
1. Size Attribute:
Size determines how many items are shown at once on the selection list. If size=”3″ were used in the preceding code, only the first three options would be visible, and a scrollbar would appear next to the list so the user could scroll down to see the third option.
Ex.: <Select name – ‘Weekday” size=4>

2. Name:
It is used to define name to the drop down menu.
<Select name =”WeekDay” size=4 multiple>

3. Multiple:
This is used to select multiple options from the given list. This is the value which has to be given back to the website and defined in the option tag.
Ex.: <optionValue=”Sunday”>Sunday
When this option is used the given option will be preselected.

Question 3.
Explain Text Area with an example.
Answer:
This is a container tag and is used to allow multiple lines of text in a single input item. It has two attributes these are ROWS and COLS. Row defines the number of rows defined in the text area and cols defines the number of columns used in the text area. If user wants to define some default text then he can define in-between the open closing tags of text area element. All this is explained in the given example. <textarea name=”comments” rows=”5″ cols=”25″>
Please type in more information.
</textarea>

Question 4.
What is the purpose of action and method in forms?
Answer:
Get Method:
This method is used to encode the fed data by the user by using URL path and is sent to the server. Limited data can be sent to the server. Its parameters remain in the browser history.
<FORM method=get action-‘ action.php”>

Post Method:
This method is used to store the data to the server without interfering JRL and is more secure to send information than GET method from the website form to the server. There is no restriction on sending data. Its parameters don’t remain in the browser history.
<form method=post action=”action.php”>

PSEB 10th Class Computer Science Solutions Chapter 3 HTML II

PSEB 10th Class Computer Guide Office Tools Important Questions and Answers

Multiple Choice Questions

Question 1.
What is used to link two pages?
(a) Page
(b) Glue
(c) Button
(d) Hyperlink
Answer:
(d) Hyperlink

Question 2.
What is not used in Form:
(a) Button
(b) Text Box
(c) Radio Button
(d) Row
Answer:
(d) Row

Question 3.
How many types of links are?
(a) 2
(b) 3
(c) 4
(d) 5
Answer:
(a) 2

Question 4.
How many types of Methods are in a form?
(a) 1
(b) 2
(c) 3
(d) 4
Answer:
(b) 2

PSEB 10th Class Computer Science Solutions Chapter 3 HTML II

Fill in the Blanks

Question 1.
The text which is highlighted in Blue is called ……………..
Answer:
Hyperlink

Question 2.
…………….. attribute is used to change color in table.
Answer:
BGCOLOR

Question 3.
………… attribute is used to change sell spacing.
Answer:
Cell spacing

Question 4.
………….. is used to change cell width. (2019)
Answer:
Colspan

Question 5.
Brower shows a hyper link in ……….color.
Answer:
Blue

PSEB 10th Class Computer Science Solutions Chapter 3 HTML II

Question 6.
…………… is used to go to another place in a webpage.
Answer:
Bookmark.

Select True/False

Question 1.
Anchor tag is used to create Hyperlink.
Answer:
False

Question 2.
<img> tag is used to insert images.
Answer:
False

Question 3.
HREF is an attribute of <img> tag.
Answer:
False

Question 4.
We can insert image in background.
Answer:
True

Question 5.
SCR is an attribute of <img> tag.
Answer:
True

PSEB 10th Class Computer Science Solutions Chapter 3 HTML II

Very Short Answer Type Questions

Question 1.
What is the use of anchor tag?
Answer:
Anchor tag is used to create hyperlink

Question 2.
What is linking?
Answer:
Linking is the process of joining two webpages.

Question 3.
What is SCR attribute?
Answer:
SCR attribute is used to tell the source of image in<img> tag.

Question 4.
What are various alignment option for an image?
Answer:

  • Left
  • Right
  • Top
  • Bottom
  • Middle.

PSEB 10th Class Computer Science Solutions Chapter 3 HTML II

Short Answer Type Questions

Question 1.
What is the purpose of submit button?
Answer:
Every form must include a button that submits the form data to the server. We can put any label on this button. It has two attributes these are type, which has submit value and value attribute defines the name of the submit button which can be displayed on the button.

Question 2.
What is Marquee?
Answer:
Marquee tag is used to move the text in html document. The text starts moving when is viewed in web browsers.

Question 3.
What is inline style?
Answer:
The style in which style is defined in the tag is called inline style. It is stored in same html document and is used when the style is not repeated anywhere in the document. It effects only to that style on which it is applied.

Long Answer Type Question

PSEB 10th Class Computer Science Solutions Chapter 3 HTML II

Question 1.
How external Movie or image can be used in HTML document?
Answer:
Adding Audio/Video files in HTML:
User can link audio/video files in HTML document using anchor (<a>) tag. User has to give the path of audio/video file in href attribute of anchor tag. Whenever the user clicks on the link, the files will automatically gets downloaded and is played in the associated software.

PSEB 10th Class Computer Notes Chapter 3 HTML II

This PSEB 10th Class Computer Notes Chapter 3 HTML II will help you in revision during exams.

PSEB 10th Class Computer Notes Chapter 3 HTML II

A hyperlink is a reference to Webpage that the reader can directly follow either by clicking, tapping or hovering. A hyperlink points to a whole document or to a specific element within a document. The text that is linked is called anchor text. A software system that is used for viewing and creating hypertext is a hypertext system, and to create a hyperlink is to hyperlink. A user following hyperlinks is said to navigate or browse the hypertext.

A webpage can contain various links that take you directly to other pages and even specific parts of a-given page. These links are known as hyperlinks. Hyperlinks allow visitors to navigate between Web sites by clicking on words, phrases, and images. Thus you can create hyperlinks using text or images available on a webpage.

PSEB 10th Class Computer Notes Chapter 3 HTML II

Linking Documents (Anchor Tag)

A link is specified using HTML tag <a>. This tag is called anchor tag and anything between the opening <a> tag and the closing </a> tag becomes part of the link and a user can click that part to reach to the lirfked document. Following is the simple syntax to use <a> tag:
<a href = “Document URL” … attributes-list>Link Text</a>

Form:

Apart from common attributes, following is a list of the most frequently used form attributes:

Attribute Description
1. action Backend script ready to process your passed data
2. method Method to be used to upload data. The most frequently used are GET and POST methods.
3. target Specify the target window or frame where the result of the script will be displayed. It takes values like Jblank, _self, _parent etc.
4. enctype The method attribute of the form element tells the web browser how to send form data to a server. Specifying a value of GET means the browser will add the form contents to the end of the URL. This offers a number of advantages for simple forms. It allows the browser to cache the results of the form submission, and it also allows the user to bookmark the page once the form has been submitted. As such, GET is generally used for simple forms where security is not a concern.

GET Method:

GET results in the entire contents of the submission being visible in the URL. If your form contains sensitive data, you should specify a value of POST for the method attribute. Since GET appends the form data to the current URL, it can only be used where the contents of the submission (including the complete URL) will result in a string that is 2048 characters long, or less. This is the maximum length of a URL. GET can only be used to send ASCII data.
<form method=”POST”>

The method attribute of the form element tells the web browser how to send form data to a server. Specifying a value of POST means the browser will send the data to the web server to be processed. This is necessary when adding data to a database, or when submitting sensitive information, such,as passwords.

PSEB 10th Class Computer Notes Chapter 3 HTML II

POST Method:

When data is sent using POST, submitting the form twice will result in a duplicated entry. This can be a problem if the form is linked to a membership, purchase, or other one-time action. This is why users cannot bookmark the results of a form submission if the method is POST.

Preparing a Form

Every form starts with <form> tag. It can be placed anywhere in html document. It ends with </form> tag.

Text Input

This control is used for items that require only one line of user input, such as search boxes or names. They are created using HTML <input> tag.

Example
Here is a basic example of a single-line text input used to take first name and last name –
PSEB 10th Class Computer Notes Chapter 3 HTML II Notes 1

Attributes:

Following is the list of attributes for <input> tag for creating text field:

Attribute Description
1. type Indicates the type of input control and for text input control it will be set to text.
2. name Used to give a name to the control which is sent to the server to be recognized and get the value.
3. value This can be used to provide an initial value inside the control.
4. size Allows to specify the width of the text-input control in terms of characters.
5. maxlength Allows to specify the maximum number of characters a user can enter into the text box

Text Area:

This is used when the user is required to give details that may be longer than a single sentence. Multi-line input controls are created using HTML <textarea> tag.

Example
Here is a basic example of a multi-line text input used to take item description:
PSEB 10th Class Computer Notes Chapter 3 HTML II Notes 2

PSEB 10th Class Computer Notes Chapter 3 HTML II

Attributes:

Following is the list of attributes for <textarea> tag:

Attribute Description
1. name Used to give a name to the control which is sent to the server to be recognized and get the value.
2. rows Indicates the number of rows of text area box.
3. cols Indicates the number of columns of text area box

Checkbox Control:

Checkboxes are used when more than one option is required to be selected. They are also created using HTML <input> tag but type attribute is set to checkbox.

Example
Here is an example HTML code for a

Attributes:

Following is the list of attributes for <checkbox> tag:

Attribute Description
type Indicates the type of input control and for checkbox input control it will be set to checkbox.
name Used to give a name to the control which is sent to the server to be recognized and get the value.
value The value that will be used if the checkbox is selected.
checked Set to checked if you want to select it by default.

Radio Button

Radio buttons are used when out of many options, just one option is required to be selected. They are also created using HTML <input> tag but type attribute is set to radio.
Example
Here is example HTML code for a form with two radio buttons:
PSEB 10th Class Computer Notes Chapter 3 HTML II Notes 3

Attributes:

Following is the list of attributes for radio button:

Attribute Description      ‘
1. type Indicates the fype of input control and for checkbox input control it will be set to radio.
2. name Used to give a name to the control which,is sent to the server to be recognized and get the value.
3. value The value that will be used if the radio box is selected.
4. checked Set to checked if you want to select it by default.

Select Box Control:

A select box, also called drop down box which provides option to list dovm various options looin the form of drop down list, from where a user can select one or more options.
Example
Here is example HTML code for a form with one drop down box
PSEB 10th Class Computer Notes Chapter 3 HTML II Notes 4

PSEB 10th Class Computer Notes Chapter 3 HTML II

Attributes:

Following is the list of important attributes of <select> tag:

Attribute Description
1. name Used to give a name to the control which is sent to the server to be recognized and get the value.
2. size This can be used to present a scrolling list box.
3. multiple If set to “multiple” then allows a user to select multiple items from the menu.

Following is the list of important attributes of <option> tag:

Attribute Description
1. value The value that will be used if an option in the select box box is selected.
2. selected Specifies that this option should be the initially selected value when the page loads.
3. label An alternative way of labeling options

Button:

There are various ways in HTML to create clickable buttons. You can also create a clickable button using <input>tag by setting its type attribute to button. The type attribute can take the following values:

Type Description
1. submit This creates a button that automatically submits a form.
2. reset This creates a button that automatically resets form controls to their initial values.

PSEB 10th Class Computer Notes Chapter 3 HTML II

Multimedia in Html:

Multimedia can be added using HTML in many ways :

<Marquee>

An HTML marquee is a scrolling piece of text displayed either horizontally across or vertically*down your webpage depending on the settings. This is created by using HTML <marquees> tag.
Note – The <marquee> tag deprecated in HTML5. Do not use this element, instead you can use JavaScript and CSS to create such effects.

Syntax:
A simple syntax to use HTML <marquee> tag is as follows:
<marquee attribute_name = “attribute_value”….more attributes> ‘
One or more lines or text message or image </marquee>

The <marquee> Tag Attributes

Following is the list of important attributes which can be used with <marquee> tag:

Width:

This specifies the width of the marquee. This can be a value like 10 or 20% etc. height. This specifies the height of the marquee. This can be a value like 10 or 20% etc. direction. This specifies the direction in which marquee should scroll. This can be a value like up, down, left or right, behavior. This specifies the type of scrolling of the marquee. This can have a value like scroll, slide and alternate, scrolldelay. This specifies how long to delay between each jump.

This will have a value like 10 etc. scrollamount. This specifies the speed of marquee text. This can have a value like 10 etc, loop. This specifies how many times to loop. The default value is INFINITE, which means that the marquee loops endlessly, bgcolor. This specifies background color in terms of color name or color hex value, shspace. This specifies horizontal space around the marquee. This can be a value like 10 or 20% etc. vspace. This specifies vertical space around the marquee. This can be a value like 10 or 20% etc.

PSEB 10th Class Computer Notes Chapter 3 HTML II

Adding Audio/Video files in HTML:

User can link audio/video files in HTML document using anchor (<a>) tag. User has to give the path of audio/video file in href attribute of anchor tag. Whenever the user clicks on the link, the files will automatically gets downloaded and is played in the associated software.