2012-04-25 7 views
1

複数のディレクトリのZeus Rewrite.Scriptの小さなヘルプを探しています - 私はサブディレクトリにWordpressを置いて動作する作業スクリプトを持っています - しかし、別のWordpress別のディレクトリへのインストール私はこれでも動作するようにリライトすることはできません。どんな助けでも大歓迎です!Zeus rewrite.script - 複数のディレクトリ

1つのディレクトリのための私のリライトは、 - 最初のディレクトリに

#Zeus webserver version of basic Wordpress mod_rewrite rules 
map path into SCRATCH:path from %{URL} 
look for file at %{SCRATCH:path} 
if exists then goto END 
look for dir at %{SCRATCH:path} 
if exists then goto END 
##### FIX FOR LOGIN/FORGOTTEN PASSWORD/ADMIN ETC##### 
match URL into $ with ^/site1/wp-.*$ 
if matched then goto END 
##### FIX TO ALLOW SEARCH TO WORK ##### 
match URL into $ with ^/oxford-walking-tours/(.*) 
set URL = /site1/index.php/$1 

だから、SITE1 - 誰もが私もSITE2のため、この作業を行うことができますどのように提案することができますか?

おかげ

答えて

0

以下のスクリプトは、すべてのZEUSサーバが をリダイレクト助けることができる1つであるそれは(あなたが任意のリダイレクトから除外したいものでこれを置き換える、あなたはまだそれを得ることができます。)はMyFolderというフォルダを無視し

その他のファイルはwwwフォーム(rule2)とwww(rule1)のないウェブサイトの.comバージョンにリダイレクトされます。

ファイルをrewrite.scriptとして保存し、サーバーのルートディレクトリにアップロードします。

#ignore anything to do with myfolder 
match URL into $ with ^/myfolder(\/)?.* 
if matched then goto END 


RULE_1_START: 
match IN:Host into $ with ^mywebsite\.net$    
if matched then    
match URL into $ with ^/(.*)$    
if matched then    
set OUT:Location = http://www.mywebsite.com/$1    
set OUT:Content-Type = text/html    
set RESPONSE = 301    
set BODY = Moved    
endif    
endif 
RULE_1_END: 

RULE_2_START: 
match IN:Host into $ with ^www.\mywebsite\.net$    
if matched then    
match URL into $ with ^/(.*)$    
if matched then    
set OUT:Location = http://www.mywebsite.com/$1    
set OUT:Content-Type = text/html    
set RESPONSE = 301    
set BODY = Moved    
endif  
endif 
RULE_2_END: 
関連する問題