问答详情
源自:3-12 企业网站制作之新闻中心制作(三)

为什么日期字号大呢

日期字号比较大   需要在news-list span里面重新设置  老师只写了颜色和右浮动  请问是怎么回事

提问者:慕粉3245911 2016-05-18 23:31

个回答

  • qq_隔壁少年郎_0
    2016-12-27 17:00:30

    连个截图都不给吗。。截取对应区域的代码。其他人也好比较嘛

    还有这个DIV里的包裹顺序是这样的。你是不是复制了其他小伙伴留言里的代码片段了?

    <div class="news-list">

                <ul>

                    <li><a href="#"></a><span></span></li>

                </ul>

     </div>


  • 慕粉3245911
    2016-05-19 21:40:13

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

    <html xmlns="http://www.w3.org/1999/xhtml">

    <head>

    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

    <title>无标题文档</title>

    <script src="../my focus/js/myfocus-2.0.1.min.js" type="text/javascript"></script>

    <script src="../my focus/js/mf-pattern/mF_YSlider.js" type="text/javascript"></script>

    <link href="../my focus/js/mf-pattern/mF_YSlider.css" rel="stylesheet" type="text/css" />

    <script type="text/javascript">

    myFocus.set({

    id:'picBox'}

    )

    </script>

    <style type="text/css">

    *{

    margin:0;

    padding:0;

    font-size:12px;

    }

    body{

    background-color:#F5F5F5;

    }

    .top{

    width:100%;

    height:27px;

    background:url(../../%E6%85%95%E8%AF%BE%E7%BB%83%E4%B9%A0/%E4%BC%81%E4%B8%9A%E7%BD%91%E7%AB%99%E5%AE%9E%E8%B7%B5%EF%BC%88%E6%BA%90%E4%BB%A3%E7%A0%81%EF%BC%89/images/top_bg.jpg)repeat-x;

    }

    .top-content{

    width:1000px;

    margin:0 auto;

    }

    .top-content li{

    list-style-image:url(../../%E6%85%95%E8%AF%BE%E7%BB%83%E4%B9%A0/%E4%BC%81%E4%B8%9A%E7%BD%91%E7%AB%99%E5%AE%9E%E8%B7%B5%EF%BC%88%E6%BA%90%E4%BB%A3%E7%A0%81%EF%BC%89/images/li_bg.gif);

    width:70px;

    float:right;

    line-height:27px;

    }

    .wrap{

    width:1000px;

    margin:0 auto;

    }

    .logo{

    height:80px;

    background:white;

    }

    .logo-left{

    width:200px;

    float:left;

    }

    .logo-right{

    width:300px;

    height:28px;

    margin-top:30px;

    float:right;

    color:#8E8E8E;

    }

    .logo-right img{

    vertical-align:middle;

    margin-right:10px;

    }

    span{

    font-family:"Microsoft YaHei UI";

    font-size:16px;

    color:red;

    }

    .nav{

    height:40px;

    }

    .nav-left{

    width:10px;

    background:url(../../%E6%85%95%E8%AF%BE%E7%BB%83%E4%B9%A0/%E4%BC%81%E4%B8%9A%E7%BD%91%E7%AB%99%E5%AE%9E%E8%B7%B5%EF%BC%88%E6%BA%90%E4%BB%A3%E7%A0%81%EF%BC%89/images/nav_left.jpg) no-repeat;

    }

    .nav-mid{

    width:980px;

    background:url(../../%E6%85%95%E8%AF%BE%E7%BB%83%E4%B9%A0/%E4%BC%81%E4%B8%9A%E7%BD%91%E7%AB%99%E5%AE%9E%E8%B7%B5%EF%BC%88%E6%BA%90%E4%BB%A3%E7%A0%81%EF%BC%89/images/nav_bg.jpg) repeat-x;

    }

    .nav-right{

    width:10px;

    background:url(../../%E6%85%95%E8%AF%BE%E7%BB%83%E4%B9%A0/%E4%BC%81%E4%B8%9A%E7%BD%91%E7%AB%99%E5%AE%9E%E8%B7%B5%EF%BC%88%E6%BA%90%E4%BB%A3%E7%A0%81%EF%BC%89/images/nav_right.jpg) no-repeat;

    }

    .nav-left,.nav-mid,.nav-right{

    float:left;

    height:40px;

    }

    .nav-mid-left,.nav-mid-right{

    float:left;

    }

    .nav-mid-left{

    width:680px;

    }

    .nav-mid-right{

    width:300px;

    }

    .nav-mid-left li{

    float:left;

    list-style:none;

    width:100px;

    text-align:;

    line-height:40px;

    }

    .nav-mid-left a:link,.nav-mid-left a:visited{

    text-decoration:none;

    color:#FFF;

    font-size:16px;

    font-family:"Microsoft YaHei UI";

    }

    .nav-mid-left a:hover,.nav-mid-left a:active{

    text-decoration:none;

    color:#FF0;

    font-size:16px;

    font-family:"Microsoft YaHei UI";

    }

    .search-text{

    width:190px;

    height:25px;

    margin-top:5px;

    background:url(../../%E6%85%95%E8%AF%BE%E7%BB%83%E4%B9%A0/%E4%BC%81%E4%B8%9A%E7%BD%91%E7%AB%99%E5%AE%9E%E8%B7%B5%EF%BC%88%E6%BA%90%E4%BB%A3%E7%A0%81%EF%BC%89/images/search.jpg) no-repeat right center;

    padding-right:25px;

    background-color:#FFF;

    border:1px solid #FFF;

    }

    .ad{

    height:310px;

    overflow:hidden;

    }

    .main{

    height:250px;

    background:#FFF;

    margin-top:5px;

    }

    .news{

    width:340px;

    border:1px solid #E8E8E8;

    }

    .course{

    width:410px;

    border:1px solid #E8E8E8;

    margin:0 7px;

    }

    .sidebar{

    width:230px;

    }

    .news,.course,.sidebar{

    height:250px;

    float:left;

    }

    .title{

    height:35px;

    border-bottom:1px solid #E8E8E8;

    }

    .title-left{

    width:70%;

    float:left;

    font-family:"Microsoft YaHei UI";

    font-size:14px;

    line-height:35px;

    font-weight:bold;

    color:#786F66;

    padding-left:20px;

    }

    .title-right{

    width:20%;

    float:right;

    line-height:35px;

    }

    .title-right a{

    text-decoration:none;

    color:#999999;

    }

    .pic-news{

    height:80px;

    margin-top:10px;

    line-height:22px;

    }

    .pic-news img{

    float:left;

    margin:0 5px;

    }

    .pic-news a{

    color:#C00;

    text-decoration:none;

    font-family:"Microsoft YaHei UI";

    }

    .news-list{

    margin-top:20px;

    }

    .news-list li{

    list-style-type:none;

    background:url(../../%E6%85%95%E8%AF%BE%E7%BB%83%E4%B9%A0/%E4%BC%81%E4%B8%9A%E7%BD%91%E7%AB%99%E5%AE%9E%E8%B7%B5%EF%BC%88%E6%BA%90%E4%BB%A3%E7%A0%81%EF%BC%89/images/list.jpg)no-repeat;

    padding-left:10px;

    margin:8px;

    border-bottom:1px dotted #CCC;

    }

    .news-list a:link,.news-list a:visited{

    color:#000;

    text-decoration:none;

    }

    .news-list a:hover,.news-list a:active{

    text-decoration:none;

    color:#F00;

    }

    .news-list span{

    color:#999;

    float:right;

    }

    </style>

    </head>


    <body>

    <div class="top">

    <div class="top-content">

            <ul>

                <li><a href="#">联系我们</a></li>

                <li><a href="#" >加入收藏</a></li>

                <li><a href="#">设为首页</a></li>

            </ul>

        </div>

    </div>

    <div class="wrap">

    <div class="logo">

        <div class="logo-left">

            <img src="../../慕课练习/企业网站实践(源代码)/images/logo.jpg" alt="慕课网" />

            </div>

            <div class="logo-right">

            <img src="../../慕课练习/企业网站实践(源代码)/images/tel.jpg" alt="服务热线" />24小时服务热线:<span class="tel">123-456-7890</span>

            </div>

        </div>

    <div class="nav">

        <div class="nav-left">

            </div>

            <div class="nav-mid">

            <div class="nav-mid-left">

                <ul>

                    <li><a href="#">首页</a></li>

                        <li><a href="list.html">关于慕课</a></li>

                        <li><a href="list.html">新闻动态</a></li>

                        <li><a href="list.html">课程中心</a></li>

                        <li><a href="list.html">在线课程</a></li>

                        <li><a href="list.html">人才招聘</a></li>

                    </ul>

                </div>

                <div class="nav-mid-right">

                <form action="" method="post">

                    <input type="text" class="search-text" />

                    </form>

                </div>

            </div>

            <div class="nav-right">

            </div>

        </div>

        <div class="ad" id="picBox">

        <div class="loading"><img src="../../慕课练习/企业网站实践(源代码)/images/loading.gif" alt="图片加载中" /></div>

        <div class="pic">

                <ul>

                    <li><img src="../../慕课练习/企业网站实践(源代码)/images/ad2.jpg" /></li>

                    <li><img src="../../慕课练习/企业网站实践(源代码)/images/ad3.jpg" /></li>

                    <li><img src="../../慕课练习/企业网站实践(源代码)/images/ad4.jpg" /></li>

                </ul>

            </div>

        </div>

        <div class="main">

        <div class="news">

            <div class="title">

                <h2 class="title-left">新闻中心</h2><span class="title-right"><a href="news.html">More&gt;&gt;</a></span>

                </div>

            <div class="pic-news">

                <img src="../../慕课练习/企业网站实践(源代码)/images/news.jpg" /><h2><a href="news.html">520 慕女神喊你来表白!</a></h2>

                    <p>活动时间:5月20日—5月25日<br />获奖公布时间:5月26日<br /><a href="news.html">Learn More&gt;&gt;</a></p>

                </div>

                <div class="news-list">

                <ul>

                    <li><span>2014-06-01</span><a href="news.html">【慕客访谈 用户篇】 “有为屌丝在路上”</a></li>

                    <li><span>2014-06-01</span><a href="news.html">【有奖活动】给父亲的三行书信</a></li>

                    <li><span>2014-05-30</span><a href="news.html">《程序猿,请晒出你的童年》活动获奖公告</a></li>

                    <li><span>2014-05-28</span><a href="news.html">【慕客访谈】 破茧成蝶--美女程序员的蜕变史</a></li>

                </ul>

                </div>

            </div>

            <div class="course">hljhlhjl</div>

            <div class="sidebar">uhljhljl</div>

        </div>

    </div>

    </div>

    </body>

    </html>


  • 老老实实做猿
    2016-05-19 18:19:06

    最好把代码 弄上来 我看看