修改首页新闻轮播的样式

This commit is contained in:
Li Jianxuan 2012-12-28 07:24:14 +00:00
parent 9401f62eb3
commit 26865a6516
2 changed files with 25 additions and 36 deletions

View File

@ -110,9 +110,10 @@
{ {
echo '<div class="slide">'. echo '<div class="slide">'.
'<div class="thumb"><img src="'.$v['image'].'" /></div>'. '<div class="thumb"><img src="'.$v['image'].'" /></div>'.
'<div class="description"><h2><a href="'.$v['url'].'">'.$v['title'].'</a></h2>'. '<div class="content">'.
'<div class="description"><h2><a href="'.$v['url'].'">'.$v['title'].'</a><span>['.date("Y-m-d",strtotime($v['ts_published'])).']</span></h2>'.
''.$v['description'].'</div>'. ''.$v['description'].'</div>'.
''. '</div>'.
'</div>'; '</div>';
} }
?> ?>
@ -163,4 +164,14 @@ $('#slides').slides({
hoverPause: true, hoverPause: true,
start: startSlide start: startSlide
}); });
$(function() {
index.init();
});
var index = {
init : function(){
$('.content').css('opacity',0.7);
}
}
</script> </script>

View File

@ -58,37 +58,11 @@ color:Green; text-decoration:none;
padding: 4px; padding: 4px;
} }
#rightPanel #feature .desc
{
margin-left: 175px;
}
#rightPanel #feature .title
{
font-size: 105%;
font-weight: bold;
padding-top: 6px;
margin-top:0px;
margin-bottom: 10px;
margin-left:185px;
}
#rightPanel #feature .description p
{margin-bottom:5px;margin-top:0px; text-indent:16px;}
#links #links
{ {
float:right;width:50px;padding:0;margin:0px;height:20px;line-height:20px; float:right;width:50px;padding:0;margin:0px;height:20px;line-height:20px;
} }
#rightPanel #feature #links a
{
padding:0;margin:0px;padding-left:15px;
background:url(../images/linkOpaque.gif) no-repeat left 0px;
height:20px;line-height:20px;
}
#rightPanel #feature .more
{ float:right;width:70px;padding:0;margin:0px;height:20px;line-height:20px;}
#rightPanel .more a{color:Green; background:url(../images/arrow.gif) no-repeat right center;padding:0 15px 0 0;margin:0px;height:20px;line-height:20px;} #rightPanel .more a{color:Green; background:url(../images/arrow.gif) no-repeat right center;padding:0 15px 0 0;margin:0px;height:20px;line-height:20px;}
#rightPanel .title #rightPanel .title
@ -106,7 +80,7 @@ color:Green; text-decoration:none;
#rightPanel #latestData{float:right; width: 250px; margin-left: 20px;} #rightPanel #latestData{float:right; width: 250px; margin-left: 20px;}
#rightPanel #feature{border-bottom: dotted 1px Gray;padding:0 0 20px 0 ;overflow:hidden;} #rightPanel #feature{border-bottom: dotted 1px Gray;overflow:hidden;}
/*数据服务段开始*/ /*数据服务段开始*/
.service_title .service_title
@ -157,13 +131,17 @@ dd,dt{margin:0;}
#dataLink dd {padding-bottom:5px;margin-left:5px;margin-top:-5px;} #dataLink dd {padding-bottom:5px;margin-left:5px;margin-top:-5px;}
#slides {overflow:hidden;} #slides {overflow:hidden;}
#slides .slide{width:520px;} #slides .slide{width:520px; position:absolute;}
#slides .slide {overflow:hidden;} #slides .slide {overflow:hidden;}
#slides .slide .thumb {float:left; overflow:hidden;} #slides .slide .thumb {width:520px;float:left;overflow:hidden;}
#slides .slide .thumb img{max-height:150px;border:1px solid #CCC;padding:2px;margin:0 5px 0 0;} #slides .slide .thumb img{width:510px;border:1px solid #CCC;padding:2px;margin:0 5px 0 0;}
#slides .slide .ctitle {float:left;overflow:hidden;} #slides .slide .content{ position:absolute;bottom:2px; left:2px; width:512px; background:#444;}
#slides .slide .ctitle {overflow:hidden; position:relative; top:0;}
#slides .slide .ctitle h2{font-weight:bold;display:block} #slides .slide .ctitle h2{font-weight:bold;display:block}
#slides .slide .description{float:left;} #slides .slide .description h2 a{color:#FFF; text-decoration:underline;}
#slides .slide .description h2 a:hover{color:#444;background:#FFF}
#slides .slide .description h2 span{font-size:12px;}
#slides .slide .description{float:left;color:#dedede}
#slides .pagination {} #slides .pagination {}
#slides .pagination li{width:10px;height:16px;padding:2px;float:left;} #slides .pagination li{width:10px;height:16px;padding:2px;float:left;}
#slides .pagination li.current{background:#dedede;color:#FFF} #slides .pagination li.current{background:#dedede;color:#FFF}