嗨,我有以下代码,但循环中的 if 语句导致语句失败,请问有什么想法吗?
@{ var count = 1; }
@foreach (var siteIcon in Model.SiteIconsList)
{
<div class="span2">
<a onclick="updateIcon(@siteIcon.ImageId)" href='#'>
<img class="iconImage" src="data:Image;base64,@(Html.Raw(Convert.ToBase64String(siteIcon.ImageData)))" alt="" />
</a>
</div>
if(count==5){
</div>
<div class="row-fluid">
count=1;
}
}