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.

Post New Thread Reply

Register GFY Rules Calendar
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >
Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed.

 
Thread Tools
Old 05-02-2010, 05:31 PM   #1
tonyparra
Confirmed User
 
tonyparra's Avatar
 
Industry Role:
Join Date: Jul 2008
Location: In your back seat with duck tape
Posts: 4,568
Wordpress, .htaccess, and mod rewrite question

Hello. I have some issues with the mod_rewrite. My situation is i have domain like so with wordpress being installed on the tld www.domain.com. I have .php pages though, that i cant import into wordpress, they are like so www.domain.com/1/page.php, www.domain.com/2/page.php, and so on. I would like to rewrite those .php extensions into .html or .htm. My problem is when i add this rules

Options +FollowSymlinks
RewriteEngine on
RewriteRule ^(.*)\.htm$ $1.php [NC]

it doesnt work and i cant log into my wordpress backend. I added that to the .htaccess file on the root level, and didnt touch any of the other wordpress stuff. Anyone know how to properly do this?
__________________

High Performance Vps $10 Linode
Manage your Digital Ocean, Linode, or Favorite Cloud Server. Simple, fast, and secure Server Pilot
tonyparra is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 05-02-2010, 05:35 PM   #2
AmeliaG
Too lazy to set a custom title
 
AmeliaG's Avatar
 
Join Date: Jan 2003
Location: Los Angeles
Posts: 10,525
I'd attempt to use the pages feature in WordPress if possible, maybe specific 301s if it is just a few pages I want to go elsewhere without losing SEO juice.
__________________
GFY Hall of Famer

AltStar Hall of Famer




Blue Blood's SpookyCash.com

Babe photography portfolio
AmeliaG is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 05-02-2010, 05:35 PM   #3
fatfoo
ICQ:649699063
 
Industry Role:
Join Date: Mar 2003
Posts: 27,763
Try asking your host support to help you with your problems.
__________________
Send me an email: [email protected]
fatfoo is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 05-02-2010, 05:48 PM   #4
fris
Too lazy to set a custom title
 
fris's Avatar
 
Industry Role:
Join Date: Aug 2002
Posts: 55,241
Quote:
Originally Posted by tonyparra View Post
Hello. I have some issues with the mod_rewrite. My situation is i have domain like so with wordpress being installed on the tld www.domain.com. I have .php pages though, that i cant import into wordpress, they are like so www.domain.com/1/page.php, www.domain.com/2/page.php, and so on. I would like to rewrite those .php extensions into .html or .htm. My problem is when i add this rules

Options +FollowSymlinks
RewriteEngine on
RewriteRule ^(.*)\.htm$ $1.php [NC]

it doesnt work and i cant log into my wordpress backend. I added that to the .htaccess file on the root level, and didnt touch any of the other wordpress stuff. Anyone know how to properly do this?
this will check to make sure a .html file doesnt exist already

http://www.domain.com/site.php will work as
http://www.domain.com/site.html

as well as dirs

http://www.domain.com/directory/sammy.php will work as
http://www.domain.com/directory/sammy.html

Code:
Options +FollowSymLinks
RewriteEngine On
RewriteCond %{SCRIPT_FILENAME} !-f
RewriteCond %{REQUEST_URI} ^(/.+\.)html$ [NC]
RewriteCond %{DOCUMENT_ROOT}%1php -f
RewriteRule \.html$ %1php [NC,QSA,L]
__________________
Since 1999: 69 Adult Industry awards for Best Hosting Company and professional excellence.


WP Stuff
fris is online now   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 05-02-2010, 07:28 PM   #5
tonyparra
Confirmed User
 
tonyparra's Avatar
 
Industry Role:
Join Date: Jul 2008
Location: In your back seat with duck tape
Posts: 4,568
Quote:
Originally Posted by fatfoo View Post
Try asking your host support to help you with your problems.
bot alert
__________________

High Performance Vps $10 Linode
Manage your Digital Ocean, Linode, or Favorite Cloud Server. Simple, fast, and secure Server Pilot
tonyparra is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 05-02-2010, 07:30 PM   #6
tonyparra
Confirmed User
 
tonyparra's Avatar
 
Industry Role:
Join Date: Jul 2008
Location: In your back seat with duck tape
Posts: 4,568
Quote:
Originally Posted by fris View Post
this will check to make sure a .html file doesnt exist already

http://www.domain.com/site.php will work as
http://www.domain.com/site.html

as well as dirs

http://www.domain.com/directory/sammy.php will work as
http://www.domain.com/directory/sammy.html

Code:
Options +FollowSymLinks
RewriteEngine On
RewriteCond %{SCRIPT_FILENAME} !-f
RewriteCond %{REQUEST_URI} ^(/.+\.)html$ [NC]
RewriteCond %{DOCUMENT_ROOT}%1php -f
RewriteRule \.html$ %1php [NC,QSA,L]
you sir are a scholar and a gentleman will try now and report
__________________

High Performance Vps $10 Linode
Manage your Digital Ocean, Linode, or Favorite Cloud Server. Simple, fast, and secure Server Pilot
tonyparra is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 05-02-2010, 07:37 PM   #7
tonyparra
Confirmed User
 
tonyparra's Avatar
 
Industry Role:
Join Date: Jul 2008
Location: In your back seat with duck tape
Posts: 4,568
thats it thanks thread closed.
__________________

High Performance Vps $10 Linode
Manage your Digital Ocean, Linode, or Favorite Cloud Server. Simple, fast, and secure Server Pilot
tonyparra is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 05-03-2010, 01:27 AM   #8
LoveSandra
So Fucking Banned
 
Join Date: Aug 2008
Location: Just Blow Me
Posts: 10,551
Quote:
Originally Posted by fatfoo View Post
Try asking your host support to help you with your problems.
LoveSandra is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 05-03-2010, 07:09 AM   #9
fris
Too lazy to set a custom title
 
fris's Avatar
 
Industry Role:
Join Date: Aug 2002
Posts: 55,241
Quote:
Originally Posted by tonyparra View Post
thats it thanks thread closed.
no problem.
__________________
Since 1999: 69 Adult Industry awards for Best Hosting Company and professional excellence.


WP Stuff
fris is online now   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Post New Thread Reply
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >

Bookmarks



Advertising inquiries - marketing at gfy dot com

Contact Admin - Advertise - GFY Rules - Top

©2000-, AI Media Network Inc



Powered by vBulletin
Copyright © 2000- Jelsoft Enterprises Limited.