新服务器上的Prestashop友好url问题

新服务器上的Prestashop友好url问题,prestashop,litespeed,Prestashop,Litespeed,我已经基于litespeed将prestashop 1.6移至另一台服务器。我刚刚将所有文件和数据库复制到新服务器。但是我对友好的URL有一个问题。产品、类别和页面链接已停止工作。 例如:旧服务器上的产品url为: 在新服务器上,此链接重定向到: 在这个重定向之后,我得到了404错误 我删除了htaccess、缓存清理和其他内容,但没有任何帮助。 有什么想法吗?此外,由于url中缺少id,图像不会显示 # ~~start~~ Do not remove this comment, Prestas

我已经基于litespeed将prestashop 1.6移至另一台服务器。我刚刚将所有文件和数据库复制到新服务器。但是我对友好的URL有一个问题。产品、类别和页面链接已停止工作。 例如:旧服务器上的产品url为: 在新服务器上,此链接重定向到: 在这个重定向之后,我得到了404错误

我删除了htaccess、缓存清理和其他内容,但没有任何帮助。 有什么想法吗?此外,由于url中缺少id,图像不会显示

# ~~start~~ Do not remove this comment, Prestashop will keep automatically the code outside this comment when .htaccess will be generated again
# .htaccess automaticaly generated by PrestaShop e-commerce open-source solution
# http://www.prestashop.com - http://www.prestashop.com/forums

<IfModule mod_rewrite.c>
<IfModule mod_env.c>
SetEnv HTTP_MOD_REWRITE On
</IfModule>

RewriteEngine on
RewriteRule . - [E=REWRITEBASE:/]
RewriteRule ^api/?(.*)$ %{ENV:REWRITEBASE}webservice/dispatcher.php?url=$1 [QSA,L]

# Images
RewriteRule ^([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$1$2$3.jpg [L]
RewriteRule ^([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$1$2$3$4.jpg [L]
RewriteRule ^([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$1$2$3$4$5.jpg [L]
RewriteRule ^([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$1$2$3$4$5$6.jpg [L]
RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$5/$1$2$3$4$5$6$7.jpg [L]
RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$5/$6/$1$2$3$4$5$6$7$8.jpg [L]
RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$5/$6/$7/$1$2$3$4$5$6$7$8$9.jpg [L]
RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$5/$6/$7/$8/$1$2$3$4$5$6$7$8$9$10.jpg [L]
RewriteRule ^c/([0-9]+)(\-[\.*_a-zA-Z0-9-]*)(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/c/$1$2$3.jpg [L]
RewriteRule ^c/([a-zA-Z_-]+)(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/c/$1$2.jpg [L]
# AlphaImageLoader for IE and fancybox
RewriteRule ^images_ie/?([^/]+)\.(jpe?g|png|gif)$ js/jquery/plugins/fancybox/images/$1.$2 [L]

# Dispatcher
RewriteCond %{REQUEST_FILENAME} -s [OR]
RewriteCond %{REQUEST_FILENAME} -l [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^.*$ - [NC,L]
RewriteRule ^.*$ %{ENV:REWRITEBASE}index.php [NC,L]
</IfModule>

AddType application/vnd.ms-fontobject .eot
AddType font/ttf .ttf
AddType font/otf .otf
AddType application/x-font-woff .woff

#If rewrite mod isn't enabled
ErrorDocument 404 /index.php?controller=404

# ~~end~~ Do not remove this comment, Prestashop will keep automatically the code outside this comment when .htaccess will be generated again
#~~开始~~不要删除此注释,当再次生成.htaccess时,Prestashop将自动将代码保留在此注释之外
#.htaccess由PrestaShop电子商务开源解决方案自动生成
# http://www.prestashop.com - http://www.prestashop.com/forums
SetEnv HTTP_MOD_重写
重新启动发动机
重写规则[E=REWRITEBASE://]
重写规则^api/?(*)$%{ENV:REWRITEBASE}webservice/dispatcher.php?url=$1[QSA,L]
#图像
重写规则^([0-9])(\-[\u a-zA-Z0-9-]*)?([0-9]+)?/.+\.jpg$%{ENV:REWRITEBASE}img/p/$1/$2$3.jpg[L]
重写规则^([0-9])([0-9])(\-[\u a-zA-Z0-9-]*)?([0-9]+)?/.+\.jpg$%{ENV:REWRITEBASE}img/p/$1/$2/$3$4.jpg[L]
重写规则^([0-9])([0-9])([0-9])(\-[\u a-zA-Z0-9-]*)?([0-9]+)?/.jpg$%{ENV:REWRITEBASE}img/p/$1/$2/$3/$1$2$3$4$5.jpg[L]
重写规则^([0-9])([0-9])([0-9])([0-9])(\-[\u a-zA-Z0-9-]*)?([0-9]+)?/.jpg$%{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$1$2$3$4$5$6.jpg[L]
重写规则^([0-9])([0-9])([0-9])([0-9])([0-9])(\-[\u a-zA-Z0-9-]*)?([0-9]+)?/.jpg$%{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$5/$1$2$3$4$5$6$7.jpg[L]
重写规则^([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])(\-[\u a-zA-Z0-9-]*)?([0-9]+)/.jpg$%{ENV:REWRITEBASE}img/p/$1/$2/$4/$5/$6/$1$2$3$4$5$6$7$8.jpg[L]
重写规则^([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])(\-[u a-zA-Z0-9-])?([0-9]+)/。+\.jpg$%{ENV:REWRITEBASE}img/p/$1/$3/$4/$6/$7/$1$2$3$4$5$7$8$9.jpg[L]
重写规则^([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])(\-[u a-zA-Z0-9-]*)?([0-9]+)/。+\.jpg$%{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$5/$8/$1$2$3$4$6$7$8/$9$10.jpg]
重写规则^c/([0-9]+)(\-[\.*U a-zA-Z0-9-]*)([0-9]+)?/.+\.jpg$%{ENV:REWRITEBASE}img/c/$1$2$3.jpg[L]
重写规则^c/([a-zA-Z-]+)([0-9]+)?/.+\.jpg$%{ENV:REWRITEBASE}img/c/$1$2.jpg[L]
#IE和fancybox的AlphaImageLoader
重写规则^images\u ie/?([^/]+)\(jpe?g | png | gif)$js/jquery/plugins/fancybox/images/$1.$2[L]
#调度员
RewriteCond%{REQUEST_FILENAME}-s[或]
RewriteCond%{REQUEST_FILENAME}-l[或]
RewriteCond%{REQUEST_FILENAME}-d
重写规则^.*$-[NC,L]
重写规则^.*${ENV:REWRITEBASE}index.php[NC,L]
AddType应用程序/vnd.ms-fontobject.eot
AddType字体/ttf.ttf
AddType字体/otf.otf
AddType应用程序/x-font-woff.woff
#如果未启用“重写模式”
ErrorDocument 404/index.php?控制器=404
#~~end~~不要删除此注释,当再次生成.htaccess时,Prestashop将自动将代码保留在此注释之外

这个问题在服务器lite中是众所周知的,我建议您安装此模块以获得良好的性能

您是否重新启动了HTTP服务器?对于Linux上的Apache2,类似于:sudo服务Apache2 restart。@whitelettersinblankpapers不,它的共享hostingLiteSpeed在处理.htaccess时只是有点不同。您可能需要指向LiteSpeed web控制台中的.htaccess文件。也许这会有帮助。@RomanK。我发现了一个问题。这些是附加的,类似于cpanel中的.htaccess规则重定向