doudou1309 2015-07-15 13:45
浏览 54

Wordpress使用//没有http或https?

For some reason my wordpress blog is using // to the path to resources. For example:

<link rel="canonical" href="//my.site.com/"/>

This is not good for SEO, but I can't seem to figure out where to go to fix this. Any ideas?

  • 写回答

1条回答 默认 最新

  • duanmu2941 2015-07-15 14:02
    关注

    go to wp-config.php, in your wordpress root, and try to change these two lines to add your website url,

    define('WP_HOME','http://example.com');
    define('WP_SITEURL','http://example.com');
    

    and open the functions.php file and make below changes,

    update_option('siteurl','http://example.com');
    update_option('home','http://example.com'); 
    

    and also try these steps,

    1)Login to WordPress admin dashboard
    2)Click on Settings >> General
    3)Fill in your WordPress Address and Site Address and click Save.
    

    finally these steps,

    1)Backup your database in cPanel prior to making changes.
    2)Use phpMyAdmin to manage your WordPress database.
    3)phpMyAdmin select WordPress databaseSelect your WordPress database from the left.
    4)Then select your wp_options table.
    5)Click Edit beside either the siteurl or home entries.
    6)Enter in your new value in the option_valuie field, then click Go
    

    enter image description here

    enter image description here

    enter image description here

    enter image description here

    at the last try to refer,

    http://www.inmotionhosting.com/support/website/wordpress/wordpress-changing-the-site-url-and-home-settings
    
    评论

报告相同问题?

悬赏问题

  • ¥15 在获取boss直聘的聊天的时候只能获取到前40条聊天数据
  • ¥20 关于URL获取的参数,无法执行二选一查询
  • ¥15 液位控制,当液位超过高限时常开触点59闭合,直到液位低于低限时,断开
  • ¥15 marlin编译错误,如何解决?
  • ¥15 有偿四位数,节约算法和扫描算法
  • ¥15 VUE项目怎么运行,系统打不开
  • ¥50 pointpillars等目标检测算法怎么融合注意力机制
  • ¥20 Vs code Mac系统 PHP Debug调试环境配置
  • ¥60 大一项目课,微信小程序
  • ¥15 求视频摘要youtube和ovp数据集