2012-12-04 78 views
0

我已經爲Joomla 2.5安裝了SH404SEF組件。它在我的生活網站上工作,但不在localhost中工作。sh404sef在localhost中不工作

我已經啓用了mod_rewrite並在我的本地主機中添加了htaccess。但它不會重定向併發生404錯誤。請幫助 enter image description here

回答

0
  • 創建全新安裝的Joomla
  • 之後,檢查是否有is.htacsess文件,
  • 否則,創建一個.htaccess文件最後
  • 安裝Sh404sef組件使用Sh404sef
  • 的控制面板
  • 啓動海基會過程中,你可以看到結果

的.htaccess樣品​​

在.htaccess文件的最後,你會看到

## Begin - Joomla! core SEF Section. 
# 
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}] 
# 
# If the requested path and file is not /index.php and the request 
# has not already been internally rewritten to the index.php script 
RewriteCond %{REQUEST_URI} !^/index\.php 
# and the request is for something within the component folder, 
# or for the site root, or for an extensionless URL, or the 
# requested URL ends with one of the listed extensions 
RewriteCond %{REQUEST_URI} /component/|(/[^.]*|\.(php|html?|feed|pdf|vcf|raw))$ [NC] 
# and the requested path and file doesn't directly match a physical file 
RewriteCond %{REQUEST_FILENAME} !-f 
# and the requested path and file doesn't directly match a physical folder 
RewriteCond %{REQUEST_FILENAME} !-d 
# internally rewrite the request to the index.php script 
RewriteRule .* index.php [L] 
# 
## End - Joomla! core SEF Section. 
0

考慮更改變量shDefaultParams ['sh404SEF_USE_NON_STANDARD_PORT'。猜猜它會爲你工作。

+0

感謝您的支持@Yesceeohhh。我錯過了.htaccess文件及其工作 –