前台展示增加收缩功能,防止页面过长

This commit is contained in:
2012-10-18 15:33:47 +08:00
parent 384d67a4b0
commit 1624ca1a7d
2 changed files with 12 additions and 3 deletions

View File

@@ -16,6 +16,7 @@ $ckname = $ckmail = $ckurl = $verifyCode = false;
$icp = Option::get('icp');
$footer_info = Option::get('footer_info');
if($res['hide'] == 'y' || !function_exists('displaySort') || !function_exists('displayRecord')) emMsg('不存在的页面!');
emLoadJQuery();
include View::getView('header');
$log_content = '<h3><input type="radio" name="show_type" onclick="switchtype(this.value)" value="record" ';
@@ -39,6 +40,14 @@ ol.archiver_item li {margin-left:1em;}
function switchtype(type){
window.location = '<?php echo BLOG_URL; ?>?plugin=archiver&show_type=' + type;
}
jQuery(function($){
if ($('ul.archiver').length) {
$('ul.archiver').find('.archiver_item:gt(3)').hide();
$('ul.archiver').find('h4').on('click', function(){
$(this).next('.archiver_item').slideToggle();
})
}
})
</script>
<?php
include View::getView('page');