[Giúp đỡ] Chèn banner quảng cáo bị vỡ bố cục

Thảo luận trong 'Style & Template Questions' bắt đầu bởi thanhtienpda, 5/7/14.

1votes
5/5, 1 vote

  1. thanhtienpda

    thanhtienpda Member

    Bài viết:
    107
    Likes :
    20
    Tinh hình là e mới chèn thêm cái banner quảng cáo vào header và footer nhưng nó lại bị vỡ bố cục như hình! Bác nào biết cách khắc phục xin chỉ giáo giùm e với ạ! Em xin chân thành cảm ơn!
    Link: www.gsmdanang.com
    Ảnh chụp Màn hình 2014-07-05 lúc 075418 Ảnh chụp Màn hình 2014-07-05 lúc 075428
     
    Đang tải...
  2. votuonq

    votuonq Member

    Bài viết:
    277
    Likes :
    139
    where is demo quảng cáo online?
     
    thanhtienpda thích bài này.
  3. thanhtienpda

    thanhtienpda Member

    Bài viết:
    107
    Likes :
    20
    dạ e mới gỡ ra xong ạ :(
     
  4. votuonq

    votuonq Member

    Bài viết:
    277
    Likes :
    139
    :D cái trang home của bạn cài bằng gì vậy ? chỉ mình với
     
  5. thanhtienpda

    thanhtienpda Member

    Bài viết:
    107
    Likes :
    20
    demo ảnh:

    Dạ đây a :)
    Edit templates
    EWRblock_RecentNews
    thay toàn bộ bằng
    Code:
    Mã:
    <xen:require css="message_user_info.css" />
    <xen:require css="bb_code.css" />
    <xen:require css="EWRblock_RecentNews.css" />
    
    <div id="recentNews">
        <xen:foreach loop="$RecentNews" value="$news">
            <div class="content_container" id="{$news.thread_id}">
    
              
                    <div class="content_threadtitle">
                        <div style="float: right; white-space: nowrap;">
                          
                            <xen:if is="{$visitor.permissions.EWRporta.canPromote}">
                                &nbsp; (<a href="{xen:link 'threads/edit', $news}" class="OverlayTrigger">{xen:phrase edit}</a>)
                            </xen:if>
                        </div>
    
                        <h2><a href="{xen:link threads, $news}" class="newsTitle">{xen:helper threadPrefix, $news}{$news.title}</a></h2>
                    </div>
    
                        <div class="content_threadinfo">
                            <span class="user"><a href="{xen:link members, $news}">{$news.username}</a></span>
                    <span class="time">{xen:time $news.post_date, 'absolute'}</span>
                    <span class="view">{xen:number $news.view_count}</span>
                    <span class="reply">{xen:number $news.reply_count}</span>
                    <span class="like">{xen:number $news.first_post_likes}</span>
                    </div>
                                    <div class="content_threadcontent">
                    <xen:if is="{$news.promote_icon} != 'disabled'">
                    <xen:if hascontent="true">
                        <div class="imgrcn">
                            <div class="avatarHolder">
                                <xen:contentcheck>
                                <xen:if is="{$news.attach}">
                                    <a href="{xen:link threads, $news}"><img src="{$news.attach.thumbnailUrl}" alt="{$news.attach.filename}" style="width: 400px;" /></a>
                                <xen:elseif is="{$news.medio}" />
                                    <div style="text-align: center;">
                                        <a href="{xen:link threads, $news}" class="imgrcn"><img src="{xen:helper medio, $news.medio}" width="320" height="180" /></a>
                                    </div>
                                <xen:elseif is="{$news.image}" />
                                    <a href="{xen:link threads, $news}"><img src="{$news.image}" alt="{$news.image}" style="max-width: 500px;" /></a>
                                <xen:else />
                                    <xen:avatar user="$news" size="l" itemprop="photo" />
                                </xen:if>
                                </xen:contentcheck>
                            </div>
                        </div>
                    </xen:if>
                    </xen:if>
    
                    <div class="messageContent baseHtml">
                      
    
                        <div class="newsText">{xen:helper stripHtml, {xen:raw $news.messageHtml}}</div>
                        <div class="clearFix"></div>
                    </div>
    
                    <div class="content_threadtools">
                        <xen:if is="{$option.social}">
                            <xen:if hascontent="true">
                                <div class="sharePage">
                                    <xen:require css="share_page.css" />
    
                                    <xen:contentcheck>
                                        <xen:hook name="recentnews_share_page_options" params="{xen:array 'url={xen:link canonical:threads, $news}'}">
                                        <xen:if is="{$xenOptions.tweet.enabled}">
                                            <div class="tweet shareControl">
                                                <a href="http://twitter.com/share" class="twitter-share-button"
                                                    data-count="horizontal"
                                                    data-lang="{xen:helper twitterLang, $visitorLanguage.language_code}"
                                                    data-url="{xen:link canonical:threads, $news}"
                                                    {xen:if {$news.title}, 'data-text="{$news.title}"'}
                                                    {xen:if {$xenOptions.tweet.via}, 'data-via="{$xenOptions.tweet.via}"'}
                                                    {xen:if {$xenOptions.tweet.related}, 'data-related="{$xenOptions.tweet.related}"'}>{xen:phrase tweet}</a>
                                            </div>
                                        </xen:if>
                                        <xen:if is="{$xenOptions.plusone}">
                                            <div class="plusone shareControl">
                                                <div class="g-plusone" data-size="medium" data-count="true" data-href="{xen:link canonical:threads, $news}" data-lang="{$visitorLanguage.language_code}"></div>
                                            </div>
                                        </xen:if>
                                        <xen:if is="{$xenOptions.facebookLike}">
                                            <div class="facebookLike shareControl">
                                                <xen:container var="$facebookSdk">1</xen:container>
                                                <fb:like href="{xen:link canonical:threads, $news}" layout="button_count" action="{$xenOptions.facebookLikeAction}" font="trebuchet ms" colorscheme="@fbColorScheme"></fb:like>
                                            </div>
                                        </xen:if>
                                        </xen:hook>
                                    </xen:contentcheck>
                                </div>
                            </xen:if>
                        <xen:else />
                            <div class="categories">
                                <ul>
                                    <xen:if is="{$visitor.permissions.EWRporta.canPromote}">
                                        <a href="{xen:link 'threads/category', $news}" class="button OverlayTrigger">+</a>
                                    </xen:if>
                                    <xen:foreach loop="$news.categories" value="$subCat">
                                        <li><a href="{xen:link 'articles', $subCat}" class="button">{$subCat.category_name}</a></li>
                                    </xen:foreach>
                                </ul>
                            </div>
                        </xen:if>
    
                        <div class="continue">
                            <a class="content_readmore" href="{xen:link threads, $news}">
                                <div class="redirect"></div>
                                {xen:phrase continue_reading}
                            </a>
                        </div>
                    </div>
                                    </div>
          
            </div>
        </xen:foreach>
    
        <xen:if hascontent="true">
        <div class="section sectionMain">
            <xen:contentcheck>
            <xen:if is="{$option.pagenav} && {$option.count} > {$option.limit}">
                <xen:if is="{$category}">
                    <xen:pagenav link="articles" linkdata="{$category}" page="{$page}" perpage="{$option.limit}" total="{$option.count}" />
                <xen:else />
                    <xen:pagenav link="portal" page="{$page}" perpage="{$option.limit}" total="{$option.count}" />
                </xen:if>
            </xen:if>
            </xen:contentcheck>
        </div>
        </xen:if>
    </div>
    EWRblock_RecentNews.css
    thay toàn bộ bằng
    Code:
    Mã:
    .content_container {
    margin-top: 5px;
    padding: 5px;
    background-color: #FFF;
    border: 1px solid #dedede;
    box-shadow: 0 0 6px #EBEBEB;
    }
    
    .content_threadtitle {
    font-family: Arial,Tahoma,sans-serif;
    font-size: 20px;
    font-weight: normal;
    color: #2b2b2b;
    text-align: left;
    display: block;
    padding: 8px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    background-color: #418797;
    margin: -5px;
    margin-bottom: 0px;
    color: #FFF;
    }
    
    .content_threadtitle h2 {
    overflow: hidden;
    text-overflow: ellipsis;
    }
    .content_threadtitle a:hover {
    text-decoration: none;
    color: #EEE;
    }
    
    .content_threadtitle a {
    color: #FFF;
    text-decoration: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    }
    
    .content_threadtools .continue {
    float: right;
    }
    
    .content_threadtools .sharePage {
    float: left;
    }
    
    .content_threadinfo {
    display: block;
    font-family: Tahoma,Arial,sans-serif;
    font-size: 12px;
    font-weight: normal;
    color: #999999;
    text-align: left;
    margin: 0px;
    border-bottom: 1px dashed #AAA;
    padding: 8px 0 7px 4px;
    position: relative;
    }
    
    .content_threadtools {
    display: block;
    margin: 0;
    max-height: 25px;
    overflow: hidden;
    margin-top: 10px;
    }
    
    .content_threadtools .content_readmore {
    display: block !important;
    background-color: #FFB636;
    color: #FFF !important;
    padding: 5px 10px !important;
    margin: 0 !important;
    float: right !important;
    text-decoration: none;
    }
    .content_threadcontent {
    display: block;
    text-align: justify;
    margin-top: 17px;
    margin-bottom: 5px;
    font-family: Arial,Tahoma,sans-serif;
    font-size: 15px;
    font-weight: normal;
    color: #333333;
    line-height: 1.4;
    }
    
    
    content_container img{text-align: center;
    max-width: 600px;
    
    }
    
    .avatarHolder {
    text-align: center;
    }
    
    .content_threadinfo .user,.content_threadinfo .time,.content_threadinfo .view,.content_threadinfo .reply,.content_threadinfo .like
    {
        display:inline-block;
        background: url(@imagePath/homeicon.png) no-repeat;
        padding: 3px 0 0 24px;
        margin: 0 10px 0 0;
        height: 20px;
        color: #999 !important;
    }
    .content_threadinfo .user{
        background-position: 0 0;
    }
    .content_threadinfo .user a
    {
        color: #999;
    }
    .content_threadinfo .user a:hover
    {
        color: #FF5302;
    }
    .content_threadinfo .time{
        background-position: 0 -32px;
    }
    .content_threadinfo .view{
        padding-left: 32px;
        background-position: 0 -57px;
    }
    .content_threadinfo .reply{
        background-position: 0 -84px;
    }
    .content_threadinfo .like{
        background-position: 0 -111px;
    }
    
    .avatar .img.l {
    width: 192px;
    height: 192px;
    display: block;
        margin-left: auto;
        margin-right: auto;
    }
    
    .imgrcn {display: block;
        margin-left: auto;
        margin-right: auto;
    }
    upload file sau vào trong thư mục chứa style hiện tại của bạn đang dùng (ví dụ: styles/gsmdanang/homeicon.png )
    Tải xuống homeicon.png
     
    tuantvpro and ngothanhvan like this.
  6. ThienHac

    ThienHac New Member

    Bài viết:
    54
    Likes :
    12
    homeicon trỏ sai đường dẫn kìa bồ . Mình nghĩ chắc do thẻ div thôi ,bạn thử thêm hoặc xóa thẻ </div> xem sao :D
     
    thanhtienpda thích bài này.
  7. thanhtienpda

    thanhtienpda Member

    Bài viết:
    107
    Likes :
    20
    Bác nào có code quảng cáo không, share cho e với ạ :D
     
  8. tuantvpro

    tuantvpro New Member

    Bài viết:
    53
    Likes :
    15
    Không hiện chữ bạn ơi.

    [​IMG]
     
  9. thanhtienpda

    thanhtienpda Member

    Bài viết:
    107
    Likes :
    20
    Bác upload file sau vào trong thư mục chứa style hiện tại của bạn đang dùng (ví dụ: styles/gsmdanang/homeicon.png )
    Tải xuống homeicon.png
     
  10. ngothanhvan

    ngothanhvan Member

    Bài viết:
    109
    Likes :
    68
    1. Sửa lỗi không hiện chữ cho bạn #8
    Tại RecentNews tìm xóa dòng
    Mã:
    <div class="newsText">{xen:helper stripHtml, {xen:raw $news.messageHtml}}</div>
    Thay bằng dòng:
    Mã:
     <div class="newsText">{xen:helper snippet, $news.message, 999}</div>
    2. Sửa lỗi không hiện Icon
    Tại RecentNews.css tìm dòng
    Mã:
     background: url(@imagePath/homeicon.png) no-repeat;
    Sửa lại thành
    Mã:
     background: url(homeicon.png) no-repeat;
    Trong đó file ảnh homeicon.png bạn up lên thư mục, ngang hàng với admin.php

    Chúc thành công

     
    thanhtienpda thích bài này.
comments powered by Disqus

Chia sẻ trang này

Đang tải...