Professional Documents
Culture Documents
Basic Education Department: Computer 8 Module
Basic Education Department: Computer 8 Module
COMPUTER 8 MODULE
SY 2022-2023 I THIRD QUARTER
II. TOPICS
Lesson 7: Uniform Design Using Cascading Style Sheets
Style sheet
III. RESOURCES
Textbook
Powerpoint Presentation
VI. BODY
Style Sheet
A web style sheet is a separate code that manipulates the overall look of the elements of your
HTML
Inline
Internal
External
Inline Style Sheet – In this style, rules are directly embedded to an HTML element using the
STYLE attribute.
This style is suitable to use when doing only a particular change in any HTML element.
Instead of defining the style once, you may only apply the style to the instance you want the
style to be applied
External Style Sheet - This style defines rules in a separate .css file and does not
contain any document content or element.
It embeds the file in an HTML document using the <link> tag.
It is advisable to use if the user needs styling for various pages.
Linking the external CSS file is similar to placing media content of your page, the
directory should be part of the code.
If you type the filename only, it means the CSS file should be in the same folder as
the HTML.
CSS RULES
Multiple style sheets can be applied in on page. Uses can apply an inline style sheet and an
internal style sheet or an internal and external style sheet at the same time.
However, there is a hierarchy to consider what style sheet has the highest priority.
CSS has two common types of selectors which are: ID and class.
Classes and IDs make it possible to specify a particular style for a variety of tags. They can also be
used to define different styles for the same HTML tag
The class selector is used to specify a style for a group of elements. This will allow users to
set a particular style for HTML elements with the same class.
ID Selector is used to indicate a style for single and unique element. This is defined with #
sign before the name.
The ID selector can be used in an internal or external style sheet.
VII. SUMMARY/CONCLUSION
Style Sheets represent a major breakthrough for Web page designers, expanding their ability to
improve the appearance of their pages. Style sheets make it easy to specify the amount of white
space between text lines, the amount lines are indented, the colors used for the text and the
backgrounds, the font size, and the style, and a host of other details.
IX. REFERENCES
A. Textbook
D-WHIZ in ICT Skills Development (Web Development Using HTML, CSS, JavaScript)
Worktext in Computer Education 8
Pages 126- 137.
Submitted by:
Checked by: