انجمن


راهنمایی در طراحی مطالب جدید  (۱ نوشته)

  • e30_007

    آفلاین
    عضو
    تعداد نوشته‌ها: ۱۸
    تشکر شده: ۴ بار
    # نوشته شده: ۱۲ سال پیش
    ۲۲ خرداد ۱۳۹۰ - ۱۶:۴۰

    سلام این قسمت رو میخواستم ویرایش کنم یه جوری که به جای این که 15 تا مطلب اخیر رو نشون بده 30 مطلبو نشون بده تو 2 تا ردیف 15 تایی و اون قسمت بعدی و قبلی که عکس داره حذف شه

    این عکس نمونه

    اینم کد قالب

    </div>
    </div>
    </div>
    <div id="ml">
    <div class="cls">
    <div class="box lh" style="margin-left: 8px;">
    <div class="box-title">مطالب جدید سایت</div>
    <div class="box-content box-height2">

    </div>
    </div>
    <div class="slide lh cls" style="margin-left: 0px;">
    <div id="myslides" style="overflow: hidden;" class="img">

    <?php $recent = new WP_Query("showposts=15"); while($recent->have_posts()) : $recent->the_post();?>

    <span>" title="<?php the_title(); ?>"><?php if(has_post_thumbnail()) {the_post_thumbnail('slide');} else {echo '<img src="'.get_bloginfo("template_url").'/images/no-image.gif" />';}?><div class="desc"><div class="lh">"><?php the_title(); ?><?php the_content_rss('', TRUE, '', 20); ?></div></div></span>

    <?php endwhile; ?>

    </div>
    <div class="bot pad3"><center>قبلیبعدی</center></div>
    </div>
    </div>

    ==================================================
    اینم style.css

    body {
    font-family: Tahoma;
    font-size: 11px;
    margin: 0px;
    padding: 0px;
    background: #E2F5FE url(images/bg.jpg) repeat-x scroll center top;
    cursor: default;
    }
    a,a:visited,a:link,a:active {
    text-decoration: none;
    color: #6F6F6F;
    }
    a:hover {
    color: #369;
    }
    .lh {
    line-height: 1.6em;
    }
    .rgt {
    direction: rtl;
    text-align: right;
    }
    .pad5 {
    padding: 5px;
    }
    .pad3{
    padding: 3px;`
    }
    ul {
    margin: 0px;
    padding: 0px;
    }
    li {
    list-style: none;
    }
    .cls{
    zoom: 1;
    }
    .cls:after {
    content: ".";
    display: block;
    height: 0px;
    clear: both;
    visibility: hidden;
    }
    .input {
    background: #FFF url(images/search.png) no-repeat scroll left center;
    padding: 5px;
    line-height: 1.6em;
    border: 1px #e8ebed solid;
    font-family: Tahoma;
    font-size: 11px;
    }
    #header {
    width: 970px;
    height: 150px;
    margin: 5px auto 0px auto;
    position: relative;
    }
    #header a,#header a:visited {
    position: absolute;
    width: 120px;
    height: 150px;
    top: 0px;
    left: 0px;
    }
    .today_text {
    position: absolute;
    top: 15px;
    right: 15px;
    color: gray;
    direction: rtl;
    }
    #footer {
    width: 970px;
    height: 70px;
    position: relative;
    margin: 0px auto 8px auto;
    background: transparent url(images/footer.png) no-repeat scroll center center;
    }
    .copyright {
    position: absolute;
    top: 45px;
    left: 15px;
    text-align: left;
    color: #626262;
    }
    .search {
    position: absolute;
    top: 22px;
    right: 25px;
    }
    .search .btn {
    background: transparent url(images/search-btn.png) no-repeat scroll center center;
    width: 70px;
    position: absolute;
    margin-right: 2px;
    height: 25px;
    cursor: pointer;
    top: 0px;
    left: 0px;
    border:none;
    }
    #wrapper {
    width: 970px;
    margin: 8px auto;
    text-align: center;
    }
    #mr {
    float: right;
    width: 170px;
    }
    #ml {
    float: left;
    width: 792px;
    }
    #left {
    float: left;
    width: 306px;
    }
    #right {
    width: 478px;
    float: right;
    }
    .main {
    border: 1px #e8ebed solid;
    background-color: #FFF;
    direction: rtl;
    text-align: right;
    margin-bottom: 8px;
    }
    .main .box-title {
    color: #000066;
    padding: 3px 0px;
    text-align: center;
    font-weight: bold;
    border-bottom: 1px #CED5D9 dashed;
    }
    .main .box-title2 {
    color: #002233;
    padding: 3px 8px;
    text-align: right;
    border-bottom: 1px #CED5D9 dashed;
    }
    .main .box-title2:before {
    content: '»';
    color: blue;
    padding-left: 10px;
    }
    .box .box-title {
    color: #000066;
    padding: 4px 8px;
    text-align: right;
    font-weight: bold;
    border-bottom: 1px #CED5D9 dashed;
    }
    .box .box-title:before {
    content: '»';
    color: blue;
    padding-left: 10px;
    }
    .box-content {
    padding: 3px 5px;
    }
    .menu-left{padding:10px;}
    .content {
    text-align: justify;
    }
    .content p {
    margin: 5px auto;
    line-height: 1.7em;
    }
    .content img {
    max-width: 458px;
    border:0;
    }
    .box {
    border: 1px #e8ebed solid;
    float: right;
    width: 390px;
    background-color: #F9FDFF;
    direction: rtl;
    text-align: right;
    margin-bottom: 8px;
    }
    .slide {
    float: right;
    width: 390px;
    }
    .slide .img {
    height: 320px;
    background-color: #F9FDFF;
    border: 1px #e8ebed solid;
    position: relative;
    }

    .slide .img img{
    height: 320px;
    width:390px;
    position: relative;
    }
    .slide .bot {
    border: 1px #e8ebed solid;
    background-color: #F9FDFF;
    direction: ltr;
    text-align: left;
    width:389px;
    }
    .img .desc {
    height: 85px;
    width: 100%;
    background: url(images/fade.png) repeat;
    position: absolute;
    bottom: 0px;
    left: 0px;
    }
    .bot a,.bot a:visited {
    border: 1px #e8ebed solid;
    background-color: #DDF4FF;
    padding: 2px 6px;
    margin-right: 3px;
    display: inline-block;
    }
    .bot a.activeSlide {
    background-color: #006595;
    color: #FFF;
    }
    .bot a:hover {
    background-color: #B0E6FF;
    }
    .desc a,.desc a:visited {
    color: #EBEBEB;
    }
    .desc a:hover {
    color: lime;
    }
    .desc div {
    padding: 5px;
    text-align: justify;
    direction: rtl;
    color: #B4B4B4;
    }
    .single {
    border-bottom: 1px #CED5D9 dashed;
    text-align: justify;
    padding: 5px;
    height: 70px;
    overflow: hidden;
    }
    .archive {
    border-top: 1px #CED5D9 dashed;
    padding: 3px 5px;
    text-align: left;
    }
    .info {
    border-top: 1px #CED5D9 dashed;
    padding: 5px 5px;
    text-align: right;
    }
    .color {
    color: #369;
    }
    .box-height {
    height: 110px;
    overflow: hidden;
    }
    .box-height2 {
    height: 320px;
    overflow: hidden;
    }
    .box-height3 {
    height: 323px;
    overflow: hidden;
    }
    .single img {
    float: right;
    margin-left: 5px;
    border: 1px #e8ebed solid;
    }
    li.dot {
    display: block;
    background: transparent url(images/dot.gif) no-repeat scroll right 10px;
    padding: 2px 10px;
    }
    li.bullet {
    display: block;
    background: transparent url(images/bullet.png) no-repeat scroll right center;
    padding: 2px 20px;

    }
    li.bullets {
    display: block;
    background: transparent url(images/hot.gif) no-repeat scroll right center;
    padding: 2px 20px;

    }
    li.cat {
    display: block;
    background: transparent none no-repeat scroll right center;
    padding: 2px 20px;
    }
    li.subcat {
    display: block;
    background: transparent none no-repeat scroll right center;
    padding: 2px 20px 2px 5px;
    margin-right: 20px;
    }
    .page-nav{padding:7px 0 17px;}
    .ads{background:none repeat scroll 0 0 #FFFFFF;border:1px solid #E8EBED;padding:10px;}

درباره‌ی این موضوع



برچسب‌ها

هیچ برچسبی نیست.