More on css

      Well , yet now you have learnt many things in css . But css still does not end . As time increases the diffrent version of css comes in existence , as the styling required more in a webpage . At this time , we can do many more things with this styling .
       Now the css3 ccomes in existence and most of the designer use it in their webpages . The most interesting thing about css3 is its animation designing , multiple background , etc . Yes , we can design an animation inour webpage through css3 .
       But we are going to discuss a different thing the border radius . You have created border in your page elements . But now you are also able to rounded cornered border . I will discuss here the same thing . The syntax for creating border radius is -
   syntax : -
 border-radius: [ radius ] ;
  
    Here , the  radius part will be either an integer or the percentage .

ex : -
 1 . border-radius:12px;
 2 . border-radius:30%;


      To use the border-radius use background of an element . whenever you give background to an element . Then background is rectangle shaped . Then you can assign different radius to each different corner . The syntax will be as -
 syntax : -
border-radius:[ radius1  radius2  radius3  radius4 ]; 


      Now the question is radius1 will be of which corner ?and some more like it ... Now I have the answer , the figure given below explain it clearly -
           so finally you can see from picture that corner no. 1 has radius1and so on . 
        If you use only two elements in radius part as -
 border-radius:[ radius1 , radius2 ];
        Then radius1 will be of corner 1 and corner 3 . And radius2 will be of corner 2 and corner 4 . A full example of four radius elements is as given below .I have created a class corner here .
   ex : -
 .corner{background:#9090cc;  text-align:center; color:red; width:600; border-radius: 18em 2em 12em 2em; }
         you can also use px instead of em I used here . But remember em is greater unit than px , so shape will be more rounded in em with same values. 
        I have created an element with the same script , and it looks as - 





               we have checked our all script with google chrome version 19.0.1084.52 .If you want to watch all effects of this css then update your browser or try to use mozilla firefox version greater than 10 . If you have any problem in the script then contact us .
                                                                                               - Thanks to visit.

drop down navigation

        After creation of simple navigation bar we will create a drop down navigation bar. A menu item that have its sub-menu item then you will need a drop down navigation bar. So , finally we are going to create a drop down navigation bar. If you have remember the code for navigation bar , so we use li:hover attribute in drop down navigation bar . So our code becomes as given -
           

<style type="text/css">
.menu ul { list-style:none; font-size:26px; }
.menu ul li { position:relative; float:left; }
.menu ul li a { text-decoration:none; padding:12px 12px 12px 12px; color:#ffffff; display:block; text-align:center; border-right:2px solid #456745; border:1px solid#467746; width:150px; background:#333333; }
.menu ul li a:hover { color:#aa2233; display:block; height:32px; background:#778877; }
.menu ul li ul { display:none; }
.menu ul li:hover ul {font-size:26px; display:block; position:absolute; top:56px; min-width:120px; left:-36px; }
.menu ul li:hover ul a {display:block; background:#000; color:#ffffff; width:144px;}
.menu ul li:hover ul li a:hover {display:block; width:148px;background:#666666; color:#aacc99;}
</style>


       The text with hyper color is new code included in previous code used in navigation bar . Include this code in your webpage and check it . To run this css your HTML list format will be as -


<div class="menu">
<ul>
<li>
<a href="#">home</a> 
<ul>
<li><a href="#">html</a></li>
<li><a href="#">css</a></li>
</ul>
</li>
<li>
<a href="#">contact</a></li>
</ul>
</div>


      Here watch the HTML code carefully I use nested list to create sub-menu items html and css of menu item home .
      I have tested this code with browser google chrome with version 19.0.1084.52 and netscape navigator 9 . If you have some problem with this code then contact us and tell about your problem . We would like to answer you.
     If you want to check my previous post on code of navigation bar then click here -  navigation bar .
     If you want to apply this navigation bar on blogger then check it  - navigation bar on blogger .
                                                                                   
                                                                                                  - Thanks to visit .