| Private Hosting Questions about VPS, dedicated servers and colocation. |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread |
|
|
#1 (permalink) |
|
Registered User
Comfy Contributor
Joined in Jul 2004
Hosted on serva
115 posts
Gave thanks: 1
Thanked 1 Time in 1 Post
|
apache's mod_rewrite
Is there somewhere where I can see if this is anabled on my server? I am not finding it. I need to see if it is my .htaccess file or something on the server.
Thanks! |
|
|
|
|
|
#2 (permalink) |
|
Skittles
Super #1
Joined in Aug 2004
Lives in a space ship
Hosted on dedi
6,810 posts
Gave thanks: 101
Thanked 199 times
|
make a file called info.php and place the following in it:
<?php phpinfo(); ?> Upload it, go to it, look for mod_rewrite and see if it is enabled
__________________
Mountain Dew Knight
People should not be afraid of their governments. Governments should be afraid of their people. |
|
|
|
|
|
#4 (permalink) |
|
after g, before i
Resident.
Joined in Jul 2004
Lives in N,BC,CA
8,079 posts
Gave thanks: 48
Thanked 131 times
|
Eh, I don't think mod_rewrite info would be in the phpinfo(). As far as I know, it's completely Apache handling it before it ever reaches anything else like PHP.
|
|
|
|
|
|
#5 (permalink) |
|
Marketing Maven
Surpass Staff
Joined in May 2003
Lives in Orlando
24,749 posts
Gave thanks: 946
Thanked 806 times
|
SSH to your server:
root yourserver [~]# grep -i mod_rewrite /usr/local/apache/conf/httpd.confThen you will see this which means it's enabled: LoadModule rewrite_module libexec/mod_rewrite.so AddModule mod_rewrite.c <IfModule mod_rewrite.c> If you don't see these lines, it's not enabled. By default, it is.
__________________
|
|
|
|
|
|
#6 (permalink) |
|
All Ur Base R Belong 2 Us
Excelling Contributor
Joined in Feb 2005
Lives in Vegas & New York
824 posts
Gave thanks: 2
Thanked 6 times
|
Haugland's right, phpinfo wouldn't be aware of the apache modules.
If you have SSH access, you can read your Apache configuration file. /usr/local/apache/etc/httpd.conf If you have WinSCP or the SSH client from SSH.com, you can download the file and open it on your PC easier. If you want, you could test through .htaccess without messing up your site Add the following lines to your .htaccess: Code:
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{REQUEST_URI} google
RewriteRule (.*) http://www.google.com [R]
</IfModule>
www.guitaristworks.com/google If you get redirected to google.com, then you're in business. Although I think they add mod rewrite as standard to these servers
__________________
Nobody doing nothing |
|
|
|
|
|
#7 (permalink) |
|
All Ur Base R Belong 2 Us
Excelling Contributor
Joined in Feb 2005
Lives in Vegas & New York
824 posts
Gave thanks: 2
Thanked 6 times
|
blip, that's what I get for trying to read stuff elsewhere also, I sat on this answer for about 10 minutes
__________________
Nobody doing nothing |
|
|
|
|
|
#9 (permalink) |
|
Skittles
Super #1
Joined in Aug 2004
Lives in a space ship
Hosted on dedi
6,810 posts
Gave thanks: 101
Thanked 199 times
|
ah dedicated
ah, that mod_rewrite maybe I should sleep
__________________
Mountain Dew Knight
People should not be afraid of their governments. Governments should be afraid of their people. |
|
|
|