+ 1

is it possible to specify different borders for different sides?? If possible ,then how?

12th Jul 2017, 6:57 PM
Debashis Ray
Debashis Ray - avatar
2 Answers
+ 5
Yes: you have to specify the differents values in a special order, each one separated by a space... Order is clockwise, starting at top side if 4 values provided. If 3 values, the middle one is for horizontal sides (left and right), top first, bottom last, and 2 for vertical (top and bottom) first and horizontal last; obviously, once value set for all four borders ^^
12th Jul 2017, 7:15 PM
visph - avatar
- 1
Yes, you can possibly set borders of different sizes , colours for different sides You can use border-top border-right border-bottom border-left to set borders to different sides according to your choice. eg. border-left:1px solid #000; border-right:2px dotted #fff; Or more preferably, Yes! You can combine all those border things in just one border property as taking border-top as first argument and then going counter clockwise to border-left for eg. border:(1px solid #333) (2px solid #000) (1px solid #333) (2px solid #000); this will set top and bottom border with #333 colour and 1px size and right and left borders with #000 and 2px
13th Jul 2017, 3:04 PM
Ankush Patil
Ankush Patil - avatar