Tuesday, December 20, 2022
Friday, December 16, 2022
Cascading sytle sheet 17 December
.
----stands for Cascading Style Sheets.
A. CSS
B. inline
C. internal
D. external
A. CSS
2.
-----describes how HTML elements are to be displayed on screen, paper, or in
other
media.
A. CSS
B. inline
C. internal
D. external
A. CSS
3.
------saves a lot of work. It can control the layout of multiple web pages all
at once.
A. CSS
B. inline
C. internal
D. external
A. CSS
4.
An------CSS is used to apply a unique style to a single HTML element
A. CSS
B. inline
C. internal
D. external
B. inline
5.
An-----CSS is defined in the <head> section of an HTML page, within
a <style> element:
A. CSS
B. inline
C. internal
D. external
C. internal
6.
With an--------style sheet, you can change the look of an entire web site, by
changing one file!
A. CSS
B. inline
C. internal
D. external
D. external
7.
An external style sheet can be written in any text editor. The file must not
contain
any HTML code, and must be saved with a -------extension.
A. .CSS
B. .TXT
C. .JS
D. .XLS
A. .CSS
8.
The CSS-------property defines the text color to be used.
A. color
B. font-family
C. font -size
D. border
A. color
9.
The CSS------property defines the font to be used.
A. color
B. font-family
C. font -size
D. border
B. font-family
10.
The CSS---------property defines the text size to be used.
A. color
B. font-family
C. font -size`
D. border
C. font -size`
11.
The CSS-------property defines a border around an HTML element:
A. color
B. font-family
C. font -size`
D. border
D. border
12.
The CSS--------property defines a margin (space) outside the border
A. color
B. font-family
C. font -size`
D. Margin
D. Margin
13.
To define a style for special types of elements, add a-----attribute is apply
to the
element
A. color
B. font-family
C. font -size`
D. class
D. class
14.
-------are used to explain the code, and may help when you edit the source code
at
a later date.
A. color
B. font-family
C. font -size`
D. comments
D. comments
15.
------are ignored by browsers.
A. color
B. font-family
C. font -size`
D. comments
D. comments
16.
------stands for -
A. Cascade style
sheets
B. Color and
style sheets
C. Cascading
style sheets
D. None of the
above
A. Cascade style
sheets
17.
Which of the following is the correct syntax for referring the external style
sheet?
A. <style src
= example.css>
B. <style src
= "example.css" >
C. <stylesheet>
example.css </stylesheet>
D. <link
rel="stylesheet" type="text/css"
href="example.css">
B. <style src
= "example.css" >
18.
The property in CSS used to change the---------of an element is -
A. bgcolor
B. color
C. background-color
D. All of the
above
C. background-color
19.
The property in CSS used to change the text-----of an element is
Sol:
-
A. bgcolor
B. color
C. background-color
D. All of the
above
B. color
20.
The CSS property used to control the element's------is -
A. text-style
B. text-size
C. font-size
D. None of the
above
C. font-size
21.
The HTML attribute used to define the inline------is -
A. style
B. styles
C. class
D. None of the
above
A. style
22.
The HTML attribute used to define the internal style sheet is ------
A. <style>
B. style
C. <link>
D. <script>
B. style
23.
Which of the following CSS property is used to set the background image of an
element?
A. background-attachment
B. background-image
C. background-color
D. None of the
above
B. background-image
24.
Which of the following is the correct syntax to make the background-color of
all
paragraph elements to yellow?
A. p
{background-color : yellow;}
B. p
{background-color : #yellow;}
C. all
{background-color : yellow;}
D. all p
{background-color : #yellow;}
A. p
{background-color : yellow;}
25.
Which of the following is the correct syntax to display the hyperlinks without
anyunderline?
A. a
{text-decoration : underline;}
B. a {decoration
: no-underline;}
C. a
{text-decoration : none;}
D. None of the
above
C. a
{text-decoration : none;}
Tuesday, December 13, 2022
CASCADING STYLE SHEET CLASS 8
1. What is the full form of css?
ans B. cascading style sheet
2. which of the following is not a css terminology?
ans D. variable
3. Which of the following can be applied to multiple webpages?
ans B. External style sheet
4. Which of the following is used to set the distance between the lines of text?
Ans- A. Line height
5. Which of the following is an invalid border property?
Ans- C. border dotted
B. Fill in the blanks
1. style
2. div tag
3. external
4. text align
5. text transform
C. True/False
1. FALSE
2. TRUE
3. TRUE
4. FALSE
5. TRUE
Thursday, December 1, 2022
CSS- CASCADING STYLE SHEETS
It is a language that describes the style of HTML document. You can set border properties,
font properties, background properties, margin properties of an HTML document using CSS.
CSS Terminology
Selector- A selector is an HTML tag at which style will be applied. This could be any tag like
<h1> , <p> or <font> etc.
Property- It is a type of attribute of HTML tag. Property includes color, background-color,
height, width, border-style, font-size etc.
Value- Values are assigned to the properties. For example- color: red
Declaration- A property and its value collectively known as declaration.
Example
Declaration Separator
Declaration
H1 {color: red; font-size: 20px}
Selector Property Value Property Value
Methods of Applying CSS
1. Inline:- In this method styles are embedded inside the HTML tag.
2. Internal:- In this method styles are placed within the header information of web page.
3. External:- In this method styles are coded as separate documents which is then referenced
from within the header of the web page..
CSS- CASCADING STYLE SHEETS
INLINE STYLES
Inline Style Sheets are included with HTML document i.e., they are placed inline with the
element. To add inline CSS, we have to declare style attribute which can contain any CSS
property. In inline Styles, declaration is enclosed in double quotes. The syntax is as follows:
<H1 STYLE= “COLOR: RED”>-------</H1>
PROGRAM TO SHOW WORKING OF INLINE STYLES
<HTML>
<HEAD>
<TITLE>CSS</TITLE>
</HEAD>
<BODY>
<H1 STYLE= “COLOR: RED”>COMPUTER</H1>
<P STYLE= “COLOR: BLUE” >
A computer is an electronic machine that works under the instructions given by
you
</P>
</BODY>
</HTML>
OUTPUT
INTERNAL STYLES
Internal Style Sheets are useful if website consists of a single page because you can change
both style rules and HTML in same file. Internal styles are defined within the <STYLE>
element, inside the <HEAD> section of an HTML page. The syntax is as follows:
<HEAD>
<STYLE TYPE= “text/css”>
H1{color:red}
</STYLE>
</HEAD>
PROGRAM TO SHOW WORKING OF INTERNAL STYLES
<HTML>
<HEAD>
<TITLE>CSS</TITLE>
<STYLE>
H1 {color: blue}
BODY {color: red}
</STYLE>
</HEAD>
<BODY>
<H1> COMPUTER</H1>
A computer is an electronic machine that works under the instructions given by
you
</BODY> </HTML>
INTERNAL STYLE SHEET
2. Internal Style Sheet
An internal style sheet may be used if one single page has a
unique style. Internal styles are defined within the
<STYLE> element, inside the <HEAD> section of an
HTML page.
e.g
HTML code save as CSS_Example_05.html.
<HTML>
<HEAD>
<STYLE type = "text/css">
HR
{color : white ;}
H1
{font-size = 40;}
P
{margin-left:20px;}
BODY
{background-image : url ("E :/Projects/COPA
/Web Design Concepts/colorful.jpg")}
</STYLE>
<TITLE>Arihant BOOKS</TITLE>
</HEAD>
<BODY>
<H1>Arihant Books </H1>
<H1>Arihant Books </H1>
<P> A wide range of books for school curricula,
polytechnic, competitive and recruitment
examinations are published by <B> Arihant
Publications India Ltd. </B> </P>
<HR style = "color: black"> For any query
e-mail at info@arihantbooks.com and
crm@arihantbooks.com or dial +91-11-40546380
</BODY>
</HTML>
Inline style
Inline Style
An inline style may be used to apply a unique style for a
single element.
To use inline styles, add the style attribute to the relevant
element. The style attribute can contain any CSS property.
e.g.
HTML code save as CSS_Example_06.html.
<HTML>
<HEAD>
<STYLE type = "text/css">
HR {color : white; }
H1 {font-size = 40;}
P {margin-left: 20px;}
BODY
{background-image: url ("E :\Projects\COPA\Web
Design Concepts\colorful.jpg"); }
</STYLE>
<TITLE> Arihant BOOKS </TITLE>
</HEAD>
<BODY>
<H1>Arihant Books </H1>
<P> A wide range of books for school curricula,
polytechnic, competitive and recruitment
examinations are published by <B> Arihant
Publications India Ltd. </B> </P>
<HR style = "color: black"> For any query
e-mail at info@arihantbooks.com and
crm@arihantbooks.com or dial +91-11-40546380
</BODY>
</HTML>
ONLINE SAFETY QUIZ FOR ALL CLASSES
https://www.safekids.com/quiz/ https://www.nspcc.org.uk/keeping-children-safe/online-safety/quiz/ https://edu.gcfglobal.org/en/internetsafe...
-
Form: It provides an easy way to collect required information from web page visitors. Web page forms have three important parts: a tag, fo...
-
PRACTICAL EXAM 2023-24 CLASS VIII HTML Q1. Write the HTML Code for the following:- a. A. India B. Srilanka c. Aust...
-
https://www.fyrebox.com/play/r4wpk5gpbqn2e83nqn/