box-sizing - floated elements
box-sizing - floated elements
I added this to a div
CODE
height:200px important; overflow:hidden; box-sizing:padding-box; padding-top:80px; float:left;
the div when rendered in FF is 280px high?
I thought box-sizing was meant to stop the padding being added to the element size?
I must be doing something wrong, so your advice is appreciated.
1DMF
"In complete darkness we are all the same, it is only our knowledge and wisdom that separates us, don't let your eyes deceive you."
"If a shortcut was meant to be easy, it wouldn't be a shortcut, it would be the way!"
Free Electronic Dance Music
RE: box-sizing - floated elements
"Firefox supports an alternative, the -moz-box-sizing property"
I'd never heard of the thing so I had a look around.
Keith
www.studiosoft.co.uk
RE: box-sizing - floated elements
Valid values are:
content-box, border-box,inital and inherit.
I think what you are looking for is border-box.
http://www.w3schools.com/cssref/css3_pr_box-sizing...
----------------------------------
Phil AKA Vacunita
----------------------------------
Ignorance is not necessarily Bliss, case in point:
Unknown has caused an Unknown Error on Unknown and must be shutdown to prevent damage to Unknown.
Web & Tech
RE: box-sizing - floated elements
Dunno what site I was on, but they showed border-box & padding-box as separate possible values, however, it still doesn't work.
Looks like Keith is correct, stupid poxy FireFox still requires vender specific pre-fix CSS3 - come on FF get it together, modern web (CSS3 / HTML5) is already here!!!!
"In complete darkness we are all the same, it is only our knowledge and wisdom that separates us, don't let your eyes deceive you."
"If a shortcut was meant to be easy, it wouldn't be a shortcut, it would be the way!"
Free Electronic Dance Music
RE: box-sizing - floated elements
I guess the site I was looking at used this property value then the CSS3 standards removed the possible 'padding-box' value?
"In complete darkness we are all the same, it is only our knowledge and wisdom that separates us, don't let your eyes deceive you."
"If a shortcut was meant to be easy, it wouldn't be a shortcut, it would be the way!"
Free Electronic Dance Music
RE: box-sizing - floated elements
CODE
And it worked, very confused, can someone advise whether this is a valid value or not?
"In complete darkness we are all the same, it is only our knowledge and wisdom that separates us, don't let your eyes deceive you."
"If a shortcut was meant to be easy, it wouldn't be a shortcut, it would be the way!"
Free Electronic Dance Music
RE: box-sizing - floated elements
The moz specific property will not work in all Browsers., Its a specific property for Firefox and other Mozilla based browsers. So IE, and maybe Chrome will likely ignore it.
----------------------------------
Phil AKA Vacunita
----------------------------------
Ignorance is not necessarily Bliss, case in point:
Unknown has caused an Unknown Error on Unknown and must be shutdown to prevent damage to Unknown.
Web & Tech
RE: box-sizing - floated elements
Thanks for the input.
"In complete darkness we are all the same, it is only our knowledge and wisdom that separates us, don't let your eyes deceive you."
"If a shortcut was meant to be easy, it wouldn't be a shortcut, it would be the way!"
Free Electronic Dance Music