redirect 404 error page and htaccess file - Webmaster Forums - Webmaster forum for HTML, PHP, ASP, CSS and more
Webmaster Forums - Webmaster forum for HTML, PHP, ASP, CSS and more
Go Back   Webmaster Forums - Webmaster forum for HTML, PHP, ASP, CSS and more > Webmaster Tech > Programming > PHP Development

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old 11-01-2007, 01:19 PM   #1 (permalink)
Junior Member
 
Join Date: Nov 2007
Posts: 1
Default redirect 404 error page and htaccess file

hello everyone,

in a bit of a pickle and am going to try to explain exactly what I need.

I have built an online community using a CMS. I want my members and visitors to be able to view member profiles by accessing it directly from their own url, eg. www.mysite.com/username.

My problem is that everything that I try gives me the error message 404 page not found. Developers are telling me to insert code into my htaccess.txt file and rename it .htaccess. But renaming the file .htaccess reaks havoc with my site and makes it disappear.

Is their anyway to create a redirect php file in order to correct this problem, or must I use the htaccess. txt file, which I have not had any success with. Thank you.
sekhmet is offline   Reply With Quote
Sponsored Links
Old 11-20-2007, 07:53 AM   #2 (permalink)
Junior Member
 
Join Date: May 2006
Posts: 86
Default Re: redirect 404 error page and htaccess file

Hello Sekhmet,

First of all, your .htaccess should look something like the this:

Options +FollowSymlinks
RewriteEngine on
RewriteRule ^(.*)$ /profile.php?username=$1 [nc]

It sounds like you are having an issue with saving the extension of .htaccess. I find it easiest to use a shell when editing my .htaccess file. Try using a different FTP utility to upload the file.
etono is offline   Reply With Quote
Old 03-24-2008, 09:50 AM   #3 (permalink)
Junior Member
 
Join Date: Mar 2008
Location: Sullivan's Gulch
Posts: 4
Send a message via MSN to baruch menachem Send a message via Skype™ to baruch menachem
Default Re: redirect 404 error page and htaccess file

Also I think a few hosts would prefer you to use their online help to set up the file, as it can cause problems for them to.

.htaccess files must not have an extension.
baruch menachem is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



» Sponsors

» Links

» Affiliates
Web Hosting
Online Backup Reviews
Marketing Find
Merchant Select
SiteMap Builder
Host Compare

» Links

» Sports Network
Paintball Forum
Football Forum
Hockey Forum
Golf Forum
Boxing Forum
Lacrosse Forum
Baseball Forum
SnowBoarding Forum
Soccer Forum
MMA Forum


All times are GMT -4. The time now is 05:09 PM.


Powered by vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.2
Webmaster Forums
Web Hosting | Chicago Web Hosting | Web Hosting