Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact us. |
|
Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed. |
|
Thread Tools |
06-11-2012, 08:45 AM | #1 |
Liv Benson to You, Bitch
Industry Role:
Join Date: Aug 2007
Location: Maryland and WV
Posts: 6,060
|
Any .htaccess and rewrite experts in the house? Need some help.
After moving one of my sites to a new server I cant get images to display. If I remove top part from htaccess file, they show up, but re-write doesn't work. If I add it back, rewrite works but all images are broken. Any idea whats causing it and why my new server doesn't like it?
Here's htaccess contents: Options +FollowSymLinks RewriteEngine on RewriteCond %{REQUEST_FILENAME} !-F RewriteCond %{REQUEST_FILENAME} !-D RewriteRule (.*) index.php [L] Thanks
__________________
|
06-11-2012, 08:49 AM | #2 |
Confirmed User
Industry Role:
Join Date: Nov 2005
Location: Spain :)
Posts: 2,231
|
Does the new server run 'ngnix' ?
|
06-11-2012, 09:14 AM | #3 |
Liv Benson to You, Bitch
Industry Role:
Join Date: Aug 2007
Location: Maryland and WV
Posts: 6,060
|
Hmm, that I do not know. How do I find out?
__________________
|
06-11-2012, 09:18 AM | #4 |
Coupon Guru
Industry Role:
Join Date: Mar 2009
Location: Minneapolis
Posts: 10,973
|
telnet to port 80 and type in:
HEAD / HTTP/1.0
__________________
Webmaster Coupons Coupons and discounts for hosting, domains, SSL Certs, and more! AmeriNOC Coupons | Certified Hosting Coupons | Hosting Coupons | Domain Name Coupons |
06-11-2012, 09:44 AM | #5 |
Liv Benson to You, Bitch
Industry Role:
Join Date: Aug 2007
Location: Maryland and WV
Posts: 6,060
|
centOS 5.5
__________________
|
06-11-2012, 10:04 AM | #6 |
Raise Your Weapon
Industry Role:
Join Date: Jun 2003
Location: Outback Australia
Posts: 15,605
|
|
06-11-2012, 10:06 AM | #7 |
Confirmed User
Industry Role:
Join Date: Feb 2004
Location: Tobacco Road
Posts: 1,568
|
Your new host is run by pastersinalot...
|
06-11-2012, 10:13 AM | #8 | |
Liv Benson to You, Bitch
Industry Role:
Join Date: Aug 2007
Location: Maryland and WV
Posts: 6,060
|
Quote:
HTTP/1.1 200 OK Date: Mon, 11 Jun 2012 17:10:22 GMT Server: Apache/2 X-Powered-By: PHP/5.2.17
__________________
|
|
06-11-2012, 10:21 AM | #9 | |
Coupon Guru
Industry Role:
Join Date: Mar 2009
Location: Minneapolis
Posts: 10,973
|
Quote:
are you getting any kind of server error?
__________________
Webmaster Coupons Coupons and discounts for hosting, domains, SSL Certs, and more! AmeriNOC Coupons | Certified Hosting Coupons | Hosting Coupons | Domain Name Coupons |
|
06-11-2012, 10:33 AM | #10 | |
Liv Benson to You, Bitch
Industry Role:
Join Date: Aug 2007
Location: Maryland and WV
Posts: 6,060
|
No. Just broken images all over. As soon as I remove this part, images work but rewrite is gone and all links aren't working
Quote:
__________________
|
|
06-11-2012, 10:50 AM | #11 | |
Coupon Guru
Industry Role:
Join Date: Mar 2009
Location: Minneapolis
Posts: 10,973
|
Quote:
RewriteRule (.*) index.php [L] to this: RewriteRule . /index.php [L] and see if it works?
__________________
Webmaster Coupons Coupons and discounts for hosting, domains, SSL Certs, and more! AmeriNOC Coupons | Certified Hosting Coupons | Hosting Coupons | Domain Name Coupons |
|
06-11-2012, 11:07 AM | #12 |
Liv Benson to You, Bitch
Industry Role:
Join Date: Aug 2007
Location: Maryland and WV
Posts: 6,060
|
That gives me 500 error
__________________
|
06-11-2012, 11:19 AM | #13 |
Confirmed User
Industry Role:
Join Date: Mar 2003
Location: ::::::::::::: :::::::::::||::::::::::: :::::::::::||::::::::::: :::::::::::||::::::::::: :::::::::::||::::::::::: :::::::::::||::::::::::: ::::::||||||||||||:::::: :::::::::::||::::::::::: :::::::::::||::::::::::: ::::::::::::::::::::::::
Posts: 7,197
|
Fucking LOVE nginx! A bad implementation wouldn't kill images based on .htaccess rules. It could bypass them if you are not correctly passing the request to apache.
You might need a rewrite base defined. Try this. Code:
Options +FollowSymLinks RewriteEngine on RewriteBase / RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} !-f RewriteRule ^(.*)$ /index.php
__________________
Amen |
06-11-2012, 11:23 AM | #14 |
Coupon Guru
Industry Role:
Join Date: Mar 2009
Location: Minneapolis
Posts: 10,973
|
I believe you need this line:
RewriteBase / Like so: Options +FollowSymLinks RewriteEngine on RewriteBase / RewriteCond %{REQUEST_FILENAME} !-F RewriteCond %{REQUEST_FILENAME} !-D edit: - Jesus Christ - beat me to it.
__________________
Webmaster Coupons Coupons and discounts for hosting, domains, SSL Certs, and more! AmeriNOC Coupons | Certified Hosting Coupons | Hosting Coupons | Domain Name Coupons |
06-11-2012, 11:28 AM | #15 | |
Liv Benson to You, Bitch
Industry Role:
Join Date: Aug 2007
Location: Maryland and WV
Posts: 6,060
|
Quote:
WTF? works once I changed it to lower case.
__________________
|
|
06-11-2012, 11:30 AM | #16 |
Liv Benson to You, Bitch
Industry Role:
Join Date: Aug 2007
Location: Maryland and WV
Posts: 6,060
|
Thanks for your help, bro.. Turns out it has to be lower case !-d and !-d. Go figure. So weird because in original script package it was in upper case and worked fine on old server.
__________________
|
06-11-2012, 11:39 AM | #17 | |
Coupon Guru
Industry Role:
Join Date: Mar 2009
Location: Minneapolis
Posts: 10,973
|
Quote:
Glad you got it working and I could be of (some) assistance
__________________
Webmaster Coupons Coupons and discounts for hosting, domains, SSL Certs, and more! AmeriNOC Coupons | Certified Hosting Coupons | Hosting Coupons | Domain Name Coupons |
|
06-11-2012, 11:51 AM | #18 |
So Fucking Banned
Industry Role:
Join Date: Feb 2006
Posts: 23,783
|
|
06-11-2012, 11:54 AM | #19 |
Porn Meister
Industry Role:
Join Date: Feb 2005
Posts: 16,443
|
Hardly any name calling. 2cents
__________________
43-922-863 Shut up and play your guitar. |