Saturday, June 29, 2013

Some Useful Css Rules, That I need it Always

1. When You Creat unordered list ul, by default there are some margins that you have to remove in order to align the list items li to their parent container ul: 

ul{
    margin:0 0 0 0;
    list-style-type: none;
    padding:0;
}

2. Targeting Microsoft Explorer 9 and before with CSS3 great rules use the valuable script PIE.

3. When you find your self want to apply rtl direction on list items <li> with  numbers like in pagination  links but you cannot , the direction will not change it is always ltr whether you put the page direction to rtl or ltr . to solve this assign a css display property   to the li element equal to flex.

 ul > li { display:flex;}
 
 
Note: Flex is a css3 property.

No comments:

Post a Comment