Authored by whb

h5的资讯页

... ... @@ -160,8 +160,8 @@ define('mobile', function(require, exports) {
/*var nowIndex = $('option').not(function() {
return !this.selected
}).index();
// $('.news-main').removeClass('current').eq(nowIndex).addClass('current');*/
$('.news-main').removeClass('current').eq(nowIndex).addClass('current');*/
window.location.href = $(this).val();
})
};
});
\ No newline at end of file
});
... ...
... ... @@ -4,7 +4,7 @@
<select>
<?php
array_unshift($this->view->tags, array('tag' => '', 'num'=> $this->view->total));
foreach ($this->view->tags as $tag):?>
foreach ($this->view->tags as $tag): if(empty($tag['num'])) continue;?>
<option value ="<?php echo url('news/index',array('tag' => $tag['tag']))?>"
<?php echo ($this->view->current_tag == $tag['tag']) ?'selected':''?>>
<?php echo sprintf("%s(%s)", $tag['tag'] == '' ? '全部资讯': $tag['tag'], $tag['num']); ?>
... ...