【问题标题】:Magento links from the sample data are broken示例数据中的 Magento 链接已损坏
【发布时间】:2015-02-15 18:43:53
【问题描述】:

我使用 wamp 安装了 magento。 Magento 可以显示主页,但是如果我从主页单击某些内容,我会得到The requested URL /magento/accessories/eyewear.html was not found on this server. 我清除了缓存并重新索引了所有内容。我找到了一些解决方案,例如 RewriteBase /magento/ 或有关 apache 虚拟主机的东西

<VirtualHost *:80>
...
<Directory /var/www/magento/>
    AllowOverride All
</Directory>
</VirtualHost>

但我不知道该怎么做。你有什么建议可以帮助我解决问题吗?我的 apache 文件夹中的 httpd.conf 有

# Virtual hosts
#Include conf/extra/httpd-vhosts.conf. 

我不知道如何解决这个问题。

【问题讨论】:

    标签: php apache magento wamp


    【解决方案1】:

    1) 确保您的 .htaccess 文件完好无损。

    从您的安装文件中重新复制它或在线查找优化版本之一,例如:http://www.learnmagento.org/magento-tutorials/best-htaccess-magento/

    2) 如果这不起作用,那么 mod_rewrite 可能在您的 WAMP 的 httpd.conf 文件中被禁用。

    在 httpd.conf 中,找到这一行:

    #LoadModule rewrite_module modules/mod_rewrite.so
    

    并更改为(删除#):

    LoadModule rewrite_module modules/mod_rewrite.so
    

    然后重新启动WAMP

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2019-08-31
      • 2015-06-30
      • 1970-01-01
      相关资源
      最近更新 更多