mrichard Posted February 4, 2010 Share Posted February 4, 2010 Hi guys, woke up this morning to a nightmare. Moved server from Apache to Zeus (namesco server) and SEO Urls no longer worked. I am running Cre-Loaded with Cre SEO. I fixed the problem and thought I would post the rewrite.script (which is .htaccess on apache) so that people can make a work around should they have the same issue. RULE_0_START: # get the document root map path into SCRATCH:DOCROOT from / # initialize our variables set SCRATCH:ORIG_URL = %{URL} set SCRATCH:REQUEST_URI = %{URL} # prepare to search for file, rewrite if its not found set SCRATCH:REQUEST_FILENAME = %{SCRATCH:DOCROOT} set SCRATCH:REQUEST_FILENAME . %{SCRATCH:REQUEST_URI} look for file at %{SCRATCH:REQUEST_FILENAME} if not exists then look for dir at %{SCRATCH:REQUEST_FILENAME} endif RULE_0_END: RULE_1_START: # cre SEO reformats for product_info.html pages # RewriteRule ^m(.*)/(.*)/p(.*)/(.*)/product_info\.html$ product_info.php?manufacturers_id=$1&products_id=$3 [QSA,L] match URL into $ with ^m(.*)\/(.*)\/p(.*)\/(.*)\/product_info\.html?(.*)$ if matched then set URL = /product_info.php?manufacturers_id=$1&products_id=$3 goto QSA_RULE_START endif # RewriteRule ^p(.*)/(.*)/product_info\.html$ product_info.php?products_id=$1 [QSA,L] match URL into $ with ^p(.*)\/(.*)\/product_info\.html?(.*)$ if matched then set URL = /product_info.php?products_id=$1 goto QSA_RULE_START endif # RewriteRule ^(.*)/c(.*)/p(.*)/(.*)/product_info\.html$ product_info.php?cPath=$2&products_id=$3 [QSA,L] match URL into $ with ^(.*)\/c(.*)\/p(.*)\/(.*)\/product_info\.html?(.*)$ if matched then set URL = /product_info.php?cPath=$2&products_id=$3 goto QSA_RULE_START endif # cre SEO reformat for index.html pages # RewriteRule ^m(.*)/(.*)/p(.*)/(.*)/index\.html$ index.php?manufacturers_id=$1&products_id=$3 [QSA,L] match URL into $ with ^m(.*)\/(.*)\/p(.*)\/(.*)\/index\.html?(.*)$ if matched then set URL = /index.php?manufacturers_id=$1&products_id=$3 goto QSA_RULE_START endif # RewriteRule ^m(.*)/(.*)/index\.html$ index.php?manufacturers_id=$1 [QSA,L] match URL into $ with ^m(.*)\/(.*)\/index\.html?(.*)$ if matched then set URL = /index.php?manufacturers_id=$1 goto QSA_RULE_START endif # RewriteRule ^(.*)/c(.*)/m(.*)/(.*)/p(.*)/(.*)/index\.html$ index.php?cPath=$2&products_id=$5 [QSA,L] match URL into $ with ^(.*)\/c(.*)\/m(.*)\/(.*)\/p(.*)\/(.*)\/index\.html?(.*)$ if matched then set URL = /index.php?cPath=$2&products_id=$5 goto QSA_RULE_START endif # RewriteRule ^(.*)/c(.*)/p(.*)/(.*)/index\.html$ index.php?cPath=$2&products_id=$3 [QSA,L] match URL into $ with ^(.*)\/c(.*)\/p(.*)\/(.*)\/index\.html?(.*)$ if matched then set URL = /index.php?cPath=$2&products_id=$3 goto QSA_RULE_START endif # RewriteRule ^(.*)/c(.*)/index\.html$ index.php?cPath=$2 [QSA,L] match URL into $ with ^(.*)\/c(.*)\/index\.html?(.*)$ if matched then set URL = /index.php?cPath=$2 goto QSA_RULE_START endif # cre SEO reformat for information.html pages # RewriteRule ^i(.*)/(.*)/information\.html$ information.php?info_id=$1 [QSA,L] match URL into $ with ^i(.*)\/(.*)\/information\.html?(.*)$ if matched then set URL = /information.php?info_id=$1 goto QSA_RULE_START endif # cre SEO reformat for pages.html pages # RewriteRule ^p(.*)/(.*)/pages\.html$ pages.php?pID=$1 [QSA,L] match URL into $ with ^p(.*)\/(.*)\/pages\.html?(.*)$ if matched then set URL = /pages.php?pID=$1 goto QSA_RULE_START endif # RewriteRule ^(.*)/c(.*)/p(.*)/(.*)/pages\.html$ pages.php?cID=$2&pID=$3 [QSA,L] match URL into $ with ^(.*)\/c(.*)\/p(.*)\/(.*)\/pages\.html?(.*)$ if matched then set URL = /pages.php?cID=$2&pID=$3 goto QSA_RULE_START endif # RewriteRule ^(.*)/c(.*)/pages\.html$ pages.php?cID=$2 [QSA,L] match URL into $ with ^(.*)\/c(.*)\/pages\.html?(.*)$ if matched then set URL = /pages.php?cID=$2 goto QSA_RULE_START endif # RewriteRule ^(.*)/CDpath(.*)/p(.*)/(.*)/pages\.html$ pages.php?CDpath=$2&pID=$3 [QSA,L] match URL into $ with ^(.*)\/CDpath(.*)\/p(.*)\/(.*)\/pages\.html?(.*)$ if matched then set URL = /pages.php?CDpath=$2&pID=$3 goto QSA_RULE_START endif # RewriteRule ^(.*)/CDpath(.*)/pages\.html$ pages.php?CDpath=$2 [QSA,L] match URL into $ with ^(.*)\/CDpath(.*)\/pages\.html?(.*)$ if matched then set URL = /pages.php?CDpath=$2 goto QSA_RULE_START endif # cre SEO reformat for articles.html pages # RewriteRule ^(.*)/t(.*)/a(.*)/(.*)/articles\.html$ articles.php?tPath=$2&articles_id=$3 [QSA,L] match URL into $ with ^(.*)\/t(.*)\/a(.*)\/(.*)\/articles\.html?(.*)$ if matched then set URL = /articles.php?tPath=$2&articles_id=$3 goto QSA_RULE_START endif # RewriteRule ^(.*)/t(.*)/articles\.html$ articles.php?tPath=$2 [QSA,L] match URL into $ with ^(.*)\/t(.*)\/articles\.html?(.*)$ if matched then set URL = /articles.php?tPath=$2 goto QSA_RULE_START endif # cre SEO reformat for article_info.html pages # RewriteRule ^a(.*)/(.*)/article_info\.html$ article_info.php?articles_id=$1 [QSA,L] match URL into $ with ^a(.*)\/(.*)\/article_info\.html?(.*)$ if matched then set URL = /article_info.php?articles_id=$1 goto QSA_RULE_START endif # RewriteRule ^(.*)/t(.*)/article_info\.html$ article_info.php?tPath=$2 [QSA,L] match URL into $ with ^(.*)\/t(.*)\/article_info\.html?(.*)$ if matched then set URL = /article_info.php?tPath=$2 goto QSA_RULE_START endif # cre SEO reformats for product_reviews.html pages # RewriteRule ^p(.*)/(.*)/product_reviews\.html$ product_reviews.php?products_id=$1 [QSA,L] match URL into $ with ^p(.*)\/(.*)\/product_reviews\.html?(.*)$ if matched then set URL = /product_reviews.php?products_id=$1 goto QSA_RULE_START endif # RewriteRule ^(.*)/c(.*)/p(.*)/(.*)/product_reviews\.html$ product_reviews.php?products_id=$3 [QSA,L] match URL into $ with ^(.*)\/c(.*)\/p(.*)\/(.*)\/product_reviews\.html?(.*)$ if matched then set URL = /product_reviews.php?products_id=$3 goto QSA_RULE_START endif # cre SEO reformats for product_reviews_info.html pages # RewriteRule ^p(.*)/(.*)/review(.*)/product_reviews_info\.html$ product_reviews_info.php?products_id=$1&reviews_id=$3 [QSA,L] match URL into $ with ^p(.*)\/(.*)\/review(.*)\/product_reviews_info\.html?(.*)$ if matched then set URL = /product_reviews_info.php?products_id=$1&reviews_id=$3 goto QSA_RULE_START endif # cre SEO reformat for FDMS pages # RewriteRule ^f(.*)/(.*)/fdm_file_detail\.html$ fdm_file_detail.php?file_id=$1 [QSA,L] match URL into $ with ^f(.*)\/(.*)\/fdm_file_detail\.html?(.*)$ if matched then set URL = /fdm_file_detail.php?file_id=$1 goto QSA_RULE_START endif # RewriteRule ^(.*)/fPath(.*)/fdm_folder_files\.html$ fdm_folder_files.php?fPath=$2 [QSA,L] match URL into $ with ^(.*)\/fPath(.*)\/fdm_folder_files\.html?(.*)$ if matched then set URL = /fdm_folder_files.php?fPath=$2 goto QSA_RULE_START endif # cre SEO reformat for FSS pages # RewriteRule ^(.*)/fPath(.*)/form(.*)/(.*)/fss_forms_detail\.html$ fss_forms_detail.php?fPath=$2&forms_id=$3 [QSA,L] match URL into $ with ^(.*)\/fPath(.*)\/form(.*)\/(.*)\/fss_forms_detail\.html?(.*)$ if matched then set URL = /fss_forms_detail.php?fPath=$2&forms_id=$3 goto QSA_RULE_START endif # RewriteRule ^(.*)/fPath(.*)/fss_forms_index\.html$ fss_forms_index.php?fPath=$2 [QSA,L] match URL into $ with ^(.*)\/fPath(.*)\/fss_forms_index\.html?(.*)$ if matched then set URL = /fss_forms_index.php?fPath=$2 goto QSA_RULE_START endif 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: There is not much documentation for Zeus rewrite.script but this works for me anyway. If you are using other SEO Url scrips, you can see the base of how to convert this to zeus above. Any problems, I will try to help. Thanks Marc Link to comment Share on other sites More sharing options...
ladokt Posted March 1, 2010 Share Posted March 1, 2010 Hi Mrichard, I have some problems with Zeus server.. I want to change from apache server to Zeus server and this is .htaccess =========================== Options All -Indexes ErrorDocument 404 /404.php RewriteEngine On RewriteRule ^([a-zA-Z0-9-]+)/([a-zA-Z0-9-/]+)/?$ index.php?act=$1&id=$2 [L] ============================ I changed in rewrite.script =========================== match URL into $ with ^/[^/]*$ if matched then set URL = /index.php?act=$1&id=$2 =========================== After I put it in root document but it not run and have error "SSI error: recursion exceeded" Could you help me? Thanks. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.