dongyuxin5353 2019-07-22 09:25
浏览 207
已采纳

函数中的the_custom_logo()在我检查元素时强制使用两个图像标记

I am working on a web page and I almost finished, but my logo doesn`t work. I need to do it via function the_custom_logo(). After I do that 2 image tags appear when I go to inspect element. I will post your picture and code.

After publishing logo in customize options in WordPress all I need is to call that custom logo function. But as you can see I have a big issue.

<a class="country-logo" href="<?php  echo site_url() ?>">
 <img class="country-logo-style" src="<?php the_custom_logo(); ?>" alt="Pro Denver Movers Logo" >
</a>

I just need this Denver logo to fit without second image showing.

I have a link to the webpage

http://prodenvermovers.wpupkeep.org/

You can check and inspect element here on webpage and see what is the actual problem.

Thanks.

  • 写回答

1条回答 默认 最新

  • dst2017 2019-07-22 09:36
    关注

    the_custom_logo will automatically echo the right HTML code to display the logo.

    try

     <a class="country-logo" href="<?php  echo site_url() ?>">
         <?php the_custom_logo(); ?>
        </a>
    
    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥100 set_link_state
  • ¥15 虚幻5 UE美术毛发渲染
  • ¥15 CVRP 图论 物流运输优化
  • ¥15 Tableau online 嵌入ppt失败
  • ¥100 支付宝网页转账系统不识别账号
  • ¥15 基于单片机的靶位控制系统
  • ¥15 真我手机蓝牙传输进度消息被关闭了,怎么打开?(关键词-消息通知)
  • ¥15 装 pytorch 的时候出了好多问题,遇到这种情况怎么处理?
  • ¥20 IOS游览器某宝手机网页版自动立即购买JavaScript脚本
  • ¥15 手机接入宽带网线,如何释放宽带全部速度