Author name: BCIS NOTES

CSS Pseudo-elements

CSS Pseudo-elements Pseudo Elements: Pseudo-element in CSS is used to add style in specified parts of an element. Example: Using style before or after an element. Syntax:      selector::pseudo-element { property:value; }   Use of Pseudo-Element Here, some examples describe the use of pseudo-element. 1. first-line Pseudo-element: It is used to make changes to […]

CSS Pseudo-elements Read More »

CSS Combinators

CSS Combinators The final selectors we will look at are called combinators, because they combine other selectors in a way that gives them a useful relationship to each other and the location of content in the document. There are four types of combinators available in CSS which are discussed below: General Sibling selector (~) Adjacent

CSS Combinators Read More »

CSS Float

CSS Float The CSS float property specifies how an element should float. The float Property The float property is used for positioning and formatting content e.g. let an image float left to the text in a container. The float property can have one of the following values: left – The element floats to the left

CSS Float Read More »

CSS Overflow

CSS Overflow The overflow property specifies whether to clip the content or to add scrollbars when the content of an element is too big to fit in the specified area. The overflow property has the following values: visible – Default. The overflow is not clipped. The content renders outside the element’s box hidden – The

CSS Overflow Read More »

CSS Position

CSS Position The position property specifies the type of positioning method used for an element (static, relative, fixed, absolute or sticky). The position Property The position property specifies the type of positioning method used for an element. There are five different position values: static relative fixed absolute sticky 1. position: static; HTML elements are positioned

CSS Position Read More »

CSS Max-width

CSS Max-width The max-width property in CSS is used to define the maximum width of an element. The value of the width cannot be larger than the value by max-width. If the content is larger then the max-width then it will go to the next line and if the content is smaller then max-width then

CSS Max-width Read More »

CSS Display

CSS Display: The display property is the most important CSS property for controlling layout. The display Property: The display property specifies if/how an element is displayed. Every HTML element has a default display value depending on what type of element it is. The default display value for most elements is block or inline. Syntax The

CSS Display Read More »

CSS Tables

CSS Tables The look of an HTML table can be greatly improved with CSS: CODE:   Result: Table Borders: To specify table borders in CSS, use the border property. CODE:   Result: This example specifies a black border for <table>, <th>, and <td> elements.   Collapse Table Borders The border-collapse property sets whether the table

CSS Tables Read More »

CSS Lists

CSS Lists Two types of list exist in CSS i.e. Unordered lists and Ordered Lists UNORDERED LISTS: In unordered lists, the list items are marked with bullets. ORDERED LISTS: In ordered lists, the list items are marked with numbers and alphabet.   The CSS list properties allow you to: Set different list item markers for

CSS Lists Read More »

CSS Text

CSS Text This chapter teaches you how to manipulate text using CSS properties. You can set the following text properties of an element − The color property is used to set the color of a text. The direction property is used to set the text direction. The letter-spacing property is used to add or subtract

CSS Text Read More »