Tip Details Add a Related Tip

Rate as: Positive Negative

Great tutorial on mod_rewrite

If you are interested in improving your skills with Apache's mod_rewrite module, there's a great tutorial to be found here: http://www.askapache.com/htaccess/crazy-advanced-mod_rewrite-tutorial.html. Even if you are an expert already, it's definitely worth reading. One of the most interesting things in this article is the list of variables that are available when you are writing expressions in mod_rewrite. He gives a very complete list, it's even more complete than the mod_rewrite documentation. For reference, here's the list:

API_VERSION
AUTH_TYPE
CONTENT_LENGTH
CONTENT_TYPE
DOCUMENT_ROOT
GATEWAY_INTERFACE
HTTPS
HTTP_ACCEPT
HTTP_ACCEPT_CHARSET
HTTP_ACCEPT_ENCODING
HTTP_ACCEPT_LANGUAGE
HTTP_CACHE_CONTROL
HTTP_CONNECTION
HTTP_COOKIE
HTTP_FORWARDED
HTTP_HOST
HTTP_KEEP_ALIVE
HTTP_PROXY_CONNECTION
HTTP_REFERER
HTTP_USER_AGENT
IS_SUBREQ
ORIG_PATH_INFO
ORIG_PATH_TRANSLATED
ORIG_SCRIPT_FILENAME
ORIG_SCRIPT_NAME
PATH
PATH_INFO
PHP_SELF
QUERY_STRING
REDIRECT_QUERY_STRING
REDIRECT_REMOTE_USER
REDIRECT_STATUS
REDIRECT_URL
REMOTE_ADDR
REMOTE_HOST
REMOTE_IDENT
REMOTE_PORT
REMOTE_USER
REQUEST_FILENAME
REQUEST_METHOD
REQUEST_TIME
REQUEST_URI
SCRIPT_FILENAME
SCRIPT_GROUP
SCRIPT_NAME
SCRIPT_URI
SCRIPT_URL
SCRIPT_USER
SERVER_ADDR
SERVER_ADMIN
SERVER_NAME
SERVER_PORT
SERVER_PROTOCOL
SERVER_SIGNATURE
SERVER_SOFTWARE
THE_REQUEST
TIME
TIME_DAY
TIME_HOUR
TIME_MIN
TIME_MON
TIME_SEC
TIME_WDAY
TIME_YEAR
TZ
UNIQUE_ID
Link: www.askapache.com...Search for more tips related to this link
Rating: no ratings, 0 total Votes
Categories: Apache mod_rewrite tutorial server regexp
Added: on Sep 12, 2008 at 10:37 am
Added By: an anonymous user
Searches: mod_rewrite tutorial server regexp apache

Comments on this Tip

Add a Comment
There are no comments for this tip
Your Comment:
(how to format)
Rate This Tip:

Verify Humanity:
Sorry, we know it's annoying, but please enter the characters shown in the image to the left so that we know you're an actual person and not an evil spammer. Thanks.
       

Related Tips

Using mod_rewrite to enforce HTTPS connections

100% positive, 0 comments
– Tip added by an anonymous user on Aug 14, 2009 at 6:01 pm

Using mod_rewrite to redirect request to new pages

100% positive, 0 comments
– Tip added by an anonymous user on Aug 14, 2009 at 4:26 pm

Increasing PHP session lifetime

Categories: PHP server Apache
100% positive, 0 comments
– Tip added by an anonymous user on Jan 23, 2009 at 12:04 pm

Error restarting apache on a Mac

Categories: Mac Apache server error
100% positive, 0 comments
– Tip added by an anonymous user on Mar 20, 2009 at 4:57 pm

Load balancing apache servers

no ratings, 0 comments
– Tip added by an anonymous user on Sep 29, 2009 at 7:30 am

Regular expressions help

Categories: regexp tutorial windows
no ratings, 0 comments
– Tip added by an anonymous user on Apr 23, 2009 at 10:01 am

Rowing Machine Benefits for the Stay-at-Home Rower and How to Best Use a Rowing Machine

96% positive, 10 comments - last added on Oct 05, 2009 at 10:37 pm
– Tip added by ferfer on Sep 16, 2009 at 5:05 pm

How to visually determine if the used car you're about to buy has been accident repaired

96% positive, 4 comments - last added 5 days ago
– Tip added by ferfer on Sep 23, 2009 at 11:32 pm

Rowing Machines for Sale: Where to Find Cheap Rowing Machines and How to Choose the Best one for You

96% positive, 15 comments - last added on Oct 06, 2009 at 2:09 pm
– Tip added by ferfer on Sep 17, 2009 at 6:28 pm

How to Get Rid of Acne with Natural Acne Treatments

95% positive, 12 comments - last added 5 days, 4 hours ago
– Tip added by ferfer on Oct 08, 2009 at 10:56 pm

How to Use a Rowing Machine Correctly in Order to Reap All its Benefits

90% positive, 5 comments - last added on Oct 05, 2009 at 10:39 pm
– Tip added by ferfer on Sep 30, 2009 at 1:46 pm

What to Do With a Car that Won't Stop Blowing Fuses

95% positive, 4 comments - last added on Nov 12, 2009 at 4:44 pm
– Tip added by ferfer on Sep 28, 2009 at 3:24 pm

How to buy used cars for sale at discount

95% positive, 3 comments - last added on Sep 24, 2009 at 3:31 pm
– Tip added by ferfer on Sep 23, 2009 at 12:10 pm

How to get your Kindle into sleep mode

94% positive, 3 comments - last added on Oct 03, 2009 at 11:22 pm
– Tip added by ferfer on Sep 30, 2009 at 3:36 pm

How to buy an auto at a car auction

100% positive, 1 comment - last added 7 hours, 17 minutes ago
– Tip added by ferfer 2 days ago

Useful Amazon Kindle DX shortcuts

100% positive, 1 comment - last added 7 hours, 7 minutes ago
– Tip added by ferfer 2 days, 1 hour ago

Apache/PHP not connecting to MySQL db after Snow Leopard upgrade

100% positive, 1 comment - last added on Oct 19, 2009 at 6:09 pm
– Tip added by an anonymous user on Sep 08, 2009 at 1:24 pm

No apache logs after Snow Leopard upgrade

Categories: Snow Leopard apache
100% positive, 1 comment - last added on Sep 18, 2009 at 10:59 am
– Tip added by an anonymous user on Sep 04, 2009 at 3:58 pm

How to convert a web page into PDF

Categories: tutorial
no ratings, 0 comments
– Tip added by kethy123456 2 days, 14 hours ago

Hide PHP server information

Categories: PHP server configuration
no ratings, 0 comments
– Tip added by an anonymous user on Aug 31, 2009 at 10:34 am