【问题标题】:How do I add right-justified Facebook and Twitter buttons to the footer of my website?如何将右对齐的 Facebook 和 Twitter 按钮添加到我网站的页脚?
【发布时间】:2023-03-13 18:24:01
【问题描述】:

我正在为我的电子商务网站使用 Volusion,并希望将 Facebook 和 Twitter 按钮/图标添加到我网站的页脚(有点像页脚中的“cc-wiki”和“Peak Internet”徽标本页)。

这是我的页脚的当前 HTML 代码。我应该添加什么代码以使版权和“Powered by Volusion”文本左对齐,并在同一行添加所需的按钮,但右对齐?

<div id="footer_bottom">
    <!--<div id="footer_right" class="right">-->

    <!--</div>-->
    <div id="copyright">
        <a href="/terms.asp">Copyright &copy; <script type="text/javascript">document.write((new Date()).getFullYear());</script>  &nbsp;Config_CompanyNameLegal&nbsp; All Rights Reserved.</a>

        <!-- ==========================================================================================
            VOLUSION LINK - BEGIN
        ===============================================================================================
        Customer has agreed per Volusion’s Terms of Service (http://www.volusion.com/agreement_monthtomonth.asp) to maintain a text hyperlink to "http://www.volusion.com" in the footer of the website. The link must be standard html, contain no javascript, and be approved by Volusion. Removing this link breaches the Volusion agreement.-->   

        <br><a style="color: #F0F0F0" href="http://www.volusion.com" title="Shopping Cart Software" target="_blank">Powered by Volusion</a>
    </div>
    <!-- ==========================================================================================
        VOLUSION LINK - END
    =========================================================================================== -->    
    </div>
</div>

【问题讨论】:

    标签: html facebook twitter footer


    【解决方案1】:

    你必须在你的 div 上使用 float: leftfloat:right(这种效果,它未经测试只是玩 CSS)。

    <div id="footer_bottom" style="display: block; width: 100%">
        <div id="powered" style="float: left">Powered by Volusion</div>
    
        <!--</div>-->
        <div id="copyright" style="float:right" ><a href="/terms.asp">Copyright &copy; <script type="text/javascript">document.write((new Date()).getFullYear());</script>  &nbsp;Config_CompanyNameLegal&nbsp; All Rights Reserved.</a>
         </div>
    </div>
    

    请记住,您应该有一个 CSS(样式表)并将我放在 style="" 中的所有内容都放入 CSS。

    例如

    /* CSS */
    #powered {
       float: left;
    }
    

    【讨论】:

      猜你喜欢
      • 2013-10-12
      • 1970-01-01
      • 2013-03-04
      • 2012-02-26
      • 1970-01-01
      • 1970-01-01
      • 2020-10-31
      • 1970-01-01
      • 2013-02-23
      相关资源
      最近更新 更多