【问题标题】:Magento 2 add /home to homepage url onlyMagento 2 仅将 /home 添加到主页 url
【发布时间】:2020-01-29 05:18:45
【问题描述】:

我尝试使用 Magento 2 管理员添加自定义 url 重写

  • Request Path = /
  • Target Path = home
  • Redirect Type = 301 Permanent

所以当用户访问主页时,url 将是 'baseurl/home'

使用此解决方案,主页存在缓存问题,因为首先会加载 baseurl 并再次重定向到 baseurl/home,因此第一次登陆将跳过缓存,因此主页很慢。

那么我们如何才能将 /home 添加到主页的 baseurl 而不进行任何重定向?

【问题讨论】:

    标签: magento2


    【解决方案1】:

    1) 在数据库中搜索 core_config_data

    2) 更改 web/unsecure/base_url 在添加值 http://127.0.0.1/homagepage/web/secure/base_url

    相同

    3) 终端中的命令rm -rf var/cache

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2020-08-12
      • 1970-01-01
      • 1970-01-01
      • 2016-08-12
      • 1970-01-01
      • 2021-07-15
      • 1970-01-01
      • 2018-12-22
      相关资源
      最近更新 更多