А РХИВ :: nginx-ru
Nginx-ru mailing list archive (nginx-ru@sysoev.ru)
[Date Prev ][Date Next ][Thread Prev ][Thread Next ][Date Index ][Thread Index ]
реврайты для nginx-a
To : nginx-ru@xxxxxxxxx
Subject : реврайты для nginx-a
From : grek777 grek777 <rurk777@xxxxxxxxx >
Date: Sun, 5 Dec 2010 02:50:53 +0500
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:date:message-id :subject:from:to:content-type; bh=3FMjYGYBuyUr6qGS2sdMZ21B992t8qLo53FARtq3mVw=; b=fQQ+rZz7awStSbnksR7jSGqeGM/r7SfbJHWwdDocirz5L9hc900xbRAO+MVGS4q/I4 quIv0Nslum7W5JZu/L9wUS0n6Bsd1cNeqlHqiCj9l4tM3dRZkBKbR2GqJVjziaTx3onM QRz4DScsDmRkoRPPvuTEQne0cLZy35fvmKWNA=
Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=jWG9LA0/U2cCAzNrNv8iDAtD7/VwMQd5cA1n2hoT6SJSX2236KnxG6VxfXLQbZCv+p oUnER5P2c3jVfWMqcF5vRFVL3Bn6U/SnZBlcviqSQ/9vrUVWy8xJdp3YvDEuAzmPVfQJ wgWHwVEaWjZtqO+5jG+9EL46WLZHze53+cQW0=
Доброго времени суток, после перехода с apache на nginx возникла проблема с реврайтами cms, реврайты для самого движка и некоторых модулей я смог найти, но не для всех, может кто-нибудь помочь перевести следующие правила для nginx:
DirectoryIndex index.php RewriteEngine On Options +FollowSymlinks -Multiviews # Редиректы RewriteRule ^page/(.*)$ index.php?cstart=$1 [L] #forum RewriteCond %{HTTP_HOST} ^forum.site.ru $
RewriteRule ^(.*)$ http://site.ru/forum/$1 [R=301,L] # DLE Forum RewriteRule ^forum(/?)+$ /?do=forum [L] RewriteRule ^forum/category_([0-9]+)(/?)+$ /?do=forum&act=category&cid=$1 [L]
RewriteRule ^forum/forum_([0-9]+)(/?)+$ /?do=forum&act=forum&fid=$1 [L] RewriteRule ^forum/forum_([0-9]+)/([0-9]+)(/?)+$ /?do=forum&act=forum&fid=$1&cstart=$2 [L] RewriteRule ^forum/topic_([0-9]+)(/?)+$ /?do=forum&act=topic&tid=$1 [L]
RewriteRule ^forum/topic_([0-9]+)/([0-9]+)(/?)+$ /?do=forum&act=topic&tid=$1&cstart=$2 [L] RewriteRule ^forum/topic_([0-9]+)/reply(/?)+$ /?do=forum&act=post&code=reply&tid=$1 [L] RewriteRule ^forum/forum_([0-9]+)/add(/?)+$ /?do=forum&act=add_topic&forum_id=$1 [L]
RewriteRule ^forum/search(/?)+$ /?do=forum&act=search [L] RewriteRule ^forum/search/([^/]+)/([0-9]+)(/?)+$ /?do=forum&act=search&search_text=$1&cstart=$2 [L] RewriteRule ^forum/subscription(/?)+$ /?do=forum&act=subscription [L]
#RedirectPermanent /forum http://forum.site.ru #Arcade RewriteRule ^arcade(/?)+$ /?do=arcade [L] RewriteRule ^arcade/play/([0-9]{1,3})/(/?)+$ /?do=arcade&op=play&gid=$1 [QSA,L]
RewriteRule ^arcade/play/([0-9]{1,3})/([^/]*)(/?)+$ /?do=arcade&op=rec&gid=$1 [L] RewriteRule ^arcade/([^/]*)/(/?)+$ /?do=arcade&cid=$1 [L] RewriteRule ^arcade/([0-9]{1,3}),([0-9]+).html(/?)+$ ?do=arcade&cstart=$1&cend=$2 [L]
RewriteRule ^arcade/([^/]*)/([0-9]{1,3}),([0-9]+).html(/?)+$ ?do=arcade&cid=$1&cstart=$2&cend=$3 [L] #Chat RewriteRule ^chat(/?)+$ /?do=chat [L] # ТВ RewriteRule ^tv-program(/?)+$ /?do=tv-program [L]
RewriteRule ^tv-program/([^/]*)(/?)+$ /?do=tv-program&period=3&date=$1 [L] RewriteRule ^tv-program/([^/]*)/([0-9]+)(/?)+$ /?do=tv-program&period=3&channel=$2&date=$1 [L] RewriteRule ^tv-program/info/([^/]*)/([0-9]+)(/?)+$ /?do=tv-program&programm=$2&date=$1&open=info [L]
# Gallery RewriteRule ^gallery(/?)+$ /index.php?do=gallery [L] RewriteRule ^gallery/page/([0-9]+)(/?)+$ /?do=gallery&cstart=$1 [L] RewriteRule ^gallery/image/([0-9]+).html(/?)+$ /?do=gallery&action="" [L]
RewriteRule ^gallery/image/([0-9]+)/page/([0-9]+)(/?)+$ /?do=gallery&action="" [L] RewriteRule ^gallery/users(/?)+$ /?do=gallery&action="" [L] RewriteRule ^gallery/users/page/([0-9]+)(/?)+$ /?do=gallery&action="" [L]
RewriteRule ^gallery/own/([^/]*)(/?)+$ /?do=gallery&action="" [L] RewriteRule ^gallery/own/([^/]*)/page/([0-9]+)(/?)+$ /?do=gallery&action="" [L] RewriteRule ^gallery/category/([^/]*)(/?)+$ /?do=gallery&action="" [L]
RewriteRule ^gallery/category/([^/]*)/page/([0-9]+)(/?)+$ /?do=gallery&action="" [L] # 301 редирект RewriteCond %{HTTP_HOST} ^www.site.ru
RewriteRule (.*) http://site.ru/$1 [R=301,L] RewriteCond %{HTTP_HOST} ^www.pod.site.ru ^M RewriteRule (.*) http://pod.site.ru/$1 [R=301,L]
_______________________________________________
nginx-ru mailing list
nginx-ru@xxxxxxxxx
http://nginx.org/mailman/listinfo/nginx-ru