我面临的div高度不一样的问题
以下是此div的代码,其中div的高度不同
<?php for($i=0; $i<4; $i++) { ?>
<div class="col-md-3">
<div class="card card-stats card-raised">
<div class="card-body">
<div class="row">
<div class="col-sm-12">
<a href="<?php echo $Row_DS['wizardpage'];?>?ds_pid=<?php echo $catid1 = Encrypt($Row_DS['id']);?>" style="color: #fff !important;" class="category_link"><button class="btn btn-primary btn-block">Add <?php echo $Row_DS['prefix'];?></button></a>
</div>
<?php if($Row_DS['id'] == '13'){
$prospectiveID = 14;
$prospectName = "Add Prospective Clients";
$fileName = "client";
} elseif($Row_DS['id'] == '15'){
$prospectiveID = 16;
$prospectName = "Add Prospective Donors";
$fileName = "donor";
} elseif($Row_DS['id'] == '17'){
$prospectiveID = 18;
$prospectName = "Add Prospective Beneficiaries";
$fileName = "beneficary";
} elseif($Row_DS['id'] == '19'){
$prospectiveID = 20;
$prospectName = "Add Prospective Employees";
$fileName = "employee";
} elseif($Row_DS['id'] == '21'){
$prospectiveID = 22;
$prospectName = "Add Prospective Contractors";
$fileName = "contractor";
} elseif($Row_DS['id'] == '23'){
$prospectiveID = "23";
$prospectName = "";
$fileName = "volunteer";
} elseif($Row_DS['id'] == '24'){
$prospectiveID = "24";
$fileName = "supplier";
$prospectName = "";
} elseif($Row_DS['id'] == '25'){
$prospectiveID = "25";
$prospectName = "";
$fileName = "minor";
} else {
$prospectiveID = "";
} ?>
<div class="col-sm-12" <?php if($prospectName == ""){?> style="display:none;" <?php } else{?> style="display:block;"<?php } ?>>
<a href="<?php echo $Row_DS['wizardpage'];?>?ds_pid=<?php echo $catid1 = Encrypt($prospectiveID);?>" style="color: #fff !important;" class="category_link"><button class="btn btn-primary btn-block"><?php echo $prospectName;?></button></a>
</div>
<div class="col-sm-12" align="center">
<label>
OR
</label>
</div>
<div class="col-sm-12" align="center">
<label>
Upload Record via Excel (.xls) Format <a href="../../uploads/samples/<?php echo $fileName;?>_sample_file_04072018.xls">Download Sample</a>
</label>
<div class="fileinput fileinput-new text-center" data-provides="fileinput">
<div class="fileinput-preview fileinput-exists thumbnail"></div>
<form id="TypeValidation<?php echo $i1;?>" method="" enctype="multipart/form-data">
<input type="hidden" id="pii_categoryid" name="pii_categoryid" value="<?php echo $Row_DS['id'];?>" />
<div>
<span class="btn btn-rose btn-round btn-file">
<span class="fileinput-new">Select File</span>
<span class="fileinput-exists">Change</span>
<input type="file" name="<?php echo $fileName;?>_attachment" id="<?php echo $fileName;?>_attachment" accept=".xlsx, .xls, .csv" />
</span>
<a href="#" class="btn btn-danger btn-round fileinput-exists" data-dismiss="fileinput"><i class="fa fa-times"></i> Remove</a>
<button type="submit" name="add_file" id="add_file" value="<?php echo $fileName;?>_file" class="btn btn-success btn-round fileinput-exists">Upload</button>
</div>
</form>
</div>
</div>
</div>
</div>
</div>
</div>
<?php } ?>
我已经尝试使用CSS属性max-height和min-height来尝试它,但是仍然无法正常工作。如何解决这个错误? b可以使用显示属性或除CSS中的属性添加以外的其他属性来解决此问题吗?