【发布时间】:2012-03-18 00:19:52
【问题描述】:
在我的数据库中,我有“最大文件数”,但我想将其设置为 0 以表示无限制。
所以我需要一种方法
if ($count >= $max){
//a value of 0 in $max should not be here
} else {
//but here
}
这是可能的还是我必须为 0 创建一个排除项?
【问题讨论】:
在我的数据库中,我有“最大文件数”,但我想将其设置为 0 以表示无限制。
所以我需要一种方法
if ($count >= $max){
//a value of 0 in $max should not be here
} else {
//but here
}
这是可能的还是我必须为 0 创建一个排除项?
【问题讨论】:
if($max && ($count >= $max)) ....
【讨论】:
if (($max !== 0) && ($count >= $max) ){
【讨论】:
if (!empty($max) && $count >= $max ) { ...
【讨论】: