本文介绍了MIN()/ MAX()的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

嗨!


为什么CSS不支持min()/ max()这样的原始函数?像


blah

{

宽度:最大(50px,20%); // 20%&但不低于50px

}


通常会很有用..


Timo

Hi!

Why doesn''t CSS support primitive functions like min()/max()? Something like

blah
{
width: max(50px,20%);// 20%& but not less than 50px
}

would really often be useful..

Timo

推荐答案




告诉微软,也许他们将来会在某些

点支持最小宽度和最大宽度。毕竟现在只有六年了,CSS2发布了




史蒂夫


-

我的理论给你起见,我的异端邪说你愤怒,

我从不回信,你不喜欢我的领带。 - 医生


Steve Pugh< st *** @ pugh.net> < http://steve.pugh.net/>



Tell Microsoft, maybe they''ll support min-width and max-width at some
point in the future. After all it''s only six years since CSS2 was
published.

Steve

--
"My theories appal you, my heresies outrage you,
I never answer letters and you don''t like my tie." - The Doctor

Steve Pugh <st***@pugh.net> <http://steve.pugh.net/>





blah {

最小宽度:50px;

最大宽度:20%;

}


如果没有,请写信给你的国会议员在浏览器中工作

每个人都使用,他们似乎都在微软的工资单上。



blah {
min-width: 50px;
max-width: 20%;
}

Write to your congressman if this doesn''t work in the browser
everybody uses, they all seem to be on Microsoft''s payroll.




因为CSS不是编程语言,因此根本不包含任何功能?



Because CSS is not a programming language and therefore doesn''t contain
any functions at all?




好​​吧,有些功能实际上称为属性中的函数

声明:url(),counter()。



Well, there are some functions actually called functions in property
declarations: url(), counter().


这篇关于MIN()/ MAX()的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-03 18:28
查看更多