LesleyT wrote:
Replace the two instances of subfolder in this script with the name of the folder which contains your joomla installation, but put this script outside of that folder, in the root folder of your website.
BUT this seems to throw out certain aspects of the web pages that are in the root folder, so clearly I haven't completely solved the problem. If there is anyone out there who can help with this I'd be grateful for your input.
Code:
RULE_0_START:
# get the document root
map path into SCRATCH:DOCROOT from /subfolder/
# initialize our variables
set SCRATCH:ORIG_URL = %{URL}
set SCRATCH:REQUEST_URI = %{URL}
# see if theres any queries in our URL
match URL into $ with ^(.*)\?(.*)$
if matched then
set SCRATCH:REQUEST_URI = $1
set SCRATCH:QUERY_STRING = $2
endif
RULE_0_END:
RULE_1_START:
# prepare to search for file, rewrite if its not found
set SCRATCH:REQUEST_FILENAME = %{SCRATCH:DOCROOT}
set SCRATCH:REQUEST_FILENAME . %{SCRATCH:REQUEST_URI}
# check to see if the file requested is an actual file or
# a directory with possibly an index. don’t rewrite if so
look for file at %{SCRATCH:REQUEST_FILENAME}
if not exists then
look for dir at %{SCRATCH:REQUEST_FILENAME}
if not exists then
set URL = /subfolder/index.php?q=%{SCRATCH:REQUEST_URI}
goto QSA_RULE_START
endif
endif
# if we made it here then its a file or dir and no rewrite
goto END
RULE_1_END:
QSA_RULE_START:
# append the query string if there was one originally
# the same as [QSA,L] for apache
match SCRATCH:ORIG_URL into % with \?(.*)$
if matched then
set URL = %{URL}&%{SCRATCH:QUERY_STRING}
endif
goto END
QSA_RULE_END:
I'd followed this way but no luck - our plateform are under Zeus as well.
1. I've put the script outside my joomla subdirectory (in my root folder).
So the URL is
creativecompany.com.au/rewrite.script - if for URL visit.
And altered the path in these two places(in the text file "rewrite.script") to include my subdirectory (
/clients/shorehire.com.au/)
Quote:
map path into SCRATCH:DOCROOT from /clients/shorehire.com.au/
set URL = /clients/shorehire.com.au/index.php?q=%{SCRATCH:REQUEST_URI}
2. Set my SEO settings in the Global Config to:
Yes, No, Yes
(I'd also tried Yes, No, No)
After that, homepage looks good, but when I visit category URLs, it shows Joomla 404 Errors - not apache 404 Errors:
http://creativecompany.com.au/clients/s ... ducts.htmlI'd also tried "NO" for suffix URL and no luck. It returned homepage layout without css.
http://creativecompany.com.au/clients/s ... ducts.htmlQuote:
404 - Component not found
You may not be able to visit this page because of:
xxxxx
xxxxx
The normal link (without SEO rewrite) still working fine - thery are all working good locally.
http://creativecompany.com.au/clients/s ... &Itemid=65Looks like the rewrite already works but not working proparly.
Anything wrong with my setting?
TO someone click on the link I'd post, I'd made SEO config to No,No,No for clients review at the moment, you may get different error results.