Showing posts with label css border. Show all posts
Showing posts with label css border. Show all posts

Sunday, February 25, 2024

css border property

   CSS box model-Border property

1] The border-top property in css is shorthand property that allows.

2] Set the width, style, and color of the top border of an element in a single declaration.

3] Simplifies the process of styling the top border by combining several individual border

      

       properties :-

       1] border-Top

       2] border-Bottom

      3]  border-right

      4] border-left

 

1] border -top  Property :-


     1] border-top-width  :-  1] property sets the width of the top border.

                                            2]  specify the width using values like pixels and percentages.

    

    2] border-top-style  :-    1] property sets the style of the top border of an element.

                                         2] choose various styles as solid, dashed, dotted, double etc   

  

     3] border-top-color :-  1] property sets th color of the top border.

                                         2] specify the color using color name RGB values etc.


css box model-Border property

  Example :-

<html>
    <head>
        <title>Padding </title>
        <style>
h3
{
    background-color: rgb(228, 239, 233);
    color: rgb(221, 56, 202);
}
.main
{
   border-top :2px solid ;
   border-top-width :2px;
   border-top-style:dotted;
   border-top-color:crimson;
}
</style>
</head>
<body>
<h3>css box model :- css padding property<br>(padding-top ,
padding-left, padding-right, padding-bottom )</h3>
 <p class="main">Learn for the https://webdesigningtheory.blogspot.com/
</p>
</body>
</html>


css box model-Border property

 Output :-

css box model-Border property \output






READ MORE

css box model-padding property

css box model-margin property

css button style

html button tag

css element selector

css text decoration

text properties in css

external css in html