Skip to main content

How to start learning Web-development

Tutorial 5 css color , border etc

Css components with explanation - 

NOTE - for more about this go to our youtube channel link
1. Color in css -
it is predefined value in css where we set color through name, RGB code  etc you can change color in border , background , font color etc 

syntax -

color: red;

code -
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>color in css</title>
<style>
.color1{
color: red;
}
.color2{
background-color: blue;
}
.color3{
border: 2px solid red;
}
</style>
</head>
<body>
<!-- lets take paragarph -->
<p class="color1">
Lorem ipsum dolor sit amet consectetur, adipisicing elit. Eos, ex obcaecati. Culpa nulla molestias consectetur maiores quia atque quas aliquid, quaerat quis. Culpa consequatur blanditiis aut dignissimos facere. Suscipit, non.
</p>
<p class="color2">
Lorem ipsum dolor sit amet consectetur, adipisicing elit. Eos, ex obcaecati. Culpa nulla molestias consectetur maiores quia atque quas aliquid, quaerat quis. Culpa consequatur blanditiis aut dignissimos facere. Suscipit, non.
</p>
<p class="color3">
Lorem ipsum dolor sit amet consectetur, adipisicing elit. Eos, ex obcaecati. Culpa nulla molestias consectetur maiores quia atque quas aliquid, quaerat quis. Culpa consequatur blanditiis aut dignissimos facere. Suscipit, non.
</p>
</body>
</html>

Live server -

Lorem ipsum dolor sit amet consectetur, adipisicing elit. Eos, ex obcaecati. Culpa nulla molestias consectetur maiores quia atque quas aliquid, quaerat quis. Culpa consequatur blanditiis aut dignissimos facere. Suscipit, non.

Lorem ipsum dolor sit amet consectetur, adipisicing elit. Eos, ex obcaecati. Culpa nulla molestias consectetur maiores quia atque quas aliquid, quaerat quis. Culpa consequatur blanditiis aut dignissimos facere. Suscipit, non.

Lorem ipsum dolor sit amet consectetur, adipisicing elit. Eos, ex obcaecati. Culpa nulla molestias consectetur maiores quia atque quas aliquid, quaerat quis. Culpa consequatur blanditiis aut dignissimos facere. Suscipit, non.


2. Border property in css -
In this property you make a border on the element with the help of specify width heigth.

Syntax -

border : 2px solid red ;

border-radius : the meaning is it make curve on the edges.

code :
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Border property </title>
<style>
/* Border property */
.container1{
border: 2px solid black;
}
.container2{
border: 2px solid black;
border-radius: 23px;

}
.container3{
/* we can do this with bottom and right and left */
border-top: 2px solid red ;
}
</style>
</head>
<body>
<p class="container1">Lorem ipsum dolor sit amet consectetur, adipisicing elit. Excepturi, necessitatibus? Libero rerum illo autem culpa. Doloribus eveniet reprehenderit autem iure quidem nesciunt id, provident dignissimos est voluptate. Vel, eius maiores.</p>
<p class="container2">Lorem ipsum dolor sit amet consectetur, adipisicing elit. Excepturi, necessitatibus? Libero rerum illo autem culpa. Doloribus eveniet reprehenderit autem iure quidem nesciunt id, provident dignissimos est voluptate. Vel, eius maiores.</p>
<p class="container3">Lorem ipsum dolor sit amet consectetur, adipisicing elit. Excepturi, necessitatibus? Libero rerum illo autem culpa. Doloribus eveniet reprehenderit autem iure quidem nesciunt id, provident dignissimos est voluptate. Vel, eius maiores.</p>
</body>
</html>

Online server -

Lorem ipsum dolor sit amet consectetur, adipisicing elit. Excepturi, necessitatibus? Libero rerum illo autem culpa. Doloribus eveniet reprehenderit autem iure quidem nesciunt id, provident dignissimos est voluptate. Vel, eius maiores.

Lorem ipsum dolor sit amet consectetur, adipisicing elit. Excepturi, necessitatibus? Libero rerum illo autem culpa. Doloribus eveniet reprehenderit autem iure quidem nesciunt id, provident dignissimos est voluptate. Vel, eius maiores.

Lorem ipsum dolor sit amet consectetur, adipisicing elit. Excepturi, necessitatibus? Libero rerum illo autem culpa. Doloribus eveniet reprehenderit autem iure quidem nesciunt id, provident dignissimos est voluptate. Vel, eius maiores.

Comments

Popular posts from this blog

C++ programming tutorial 5

 Call by value or reference - There are two type in function call by value or call by reference in it we pass the value in call by value we pass value and in call by reference we pass the reference of the value . Call by value in C++ Programming language  :- In call by value we pass the variable or say argument and then it used by function which we made so see the code given below  Syntax - #include <iostream > using namespace std; // making function  void fun_name(int a, int b) { ... } int main() { //calling function  fun_name(int n,int n1); return 0; } Code -  // function call by value in C++ programming #include <iostream> using namespace std; // call by value in function declaration void container(int a, int b); int main() {   int x,y;   cout<<"Enter the value of x :"<<endl;   cin>>x;   cout<<"Enter the value of y :"<<endl;   cin>>y;   // here we passing the value as argument   // and also calling the function  

Class and Object , function overloading Explanation in c++ language

 Classes in C language - It is a user defined data type data type which hold its own data members and member function which can be accessed and user by creating an instance of that class and we say that class is building block that leads to Object Oriented programming  Data member -  It is the data variable of the function  Member function - It are the function use to manipulate these function variable  For Example -  A car is an object the car has attribute such as weight , color and methods such as drive and brake Attribute and method are basically variable and function that belong to class syntax - class   class{        // The class    public :              // Access specifier      int   Num;         // Attribute (int variable)     string word;   // Attribute (string variable) }; Program - // class explaination #include <iostream> using   namespace  std; class   classname {      public:      string   mystring ;      void   printfun ()     {          cout   <<   "Gee

Tutorial 10 text align , decoration etc explaining

 Text in Css - 1.Text color -     here we can set color in text for making them more enhancive or if we want required to change in color of text it work perfectly  syntax - color : red; OUTPUT - text color is change to red 2.Text alignment -     It is used for align the text according to the requirement and their situation we align text at center , right , left etc syntax - text-align:center; 3.Text decoration-     It is to decorate the text let if we want to underline in text then we use text decoration and make it on the line  syntax - text-decoration: underline; OUTPUT - text have an underline decoration 4.Text transformation -  In this we transform letters into uppercase , lowercase and capitalization means if the letter is small then it will convert into uppercase or visa-versa syntax - text-transform:(uppercase , lowercase , capitalize); 5.Text spacing - It decided the space between letter and words both how many gap are between an letters and word but syntax for both is diffe