|
|
||||||
|
||||||
| Index Link To US Private Messages Archive FAQ RSS | ||||||
| IT Discussion Forum Having IT issues? Got IT questions? Who doesn't? If you can't get your Apache to work with your MySQL or your php is choking on your ODBC... Let's see if we can help you come up with some ideas. |
Share Thread: & Tags
|
||||
|
![]() |
|
|
LinkBack | Thread Tools | Display Modes |
|
||||
|
I am trying to get to grips with .htaccess and mod_rewrite but i am lacking experience in this area so please go easy on me.
Im tryin to setup two 301s for a customer. The first solves the "domain.com" redirecting to "www.domain.com" issue. I added an .htaccess file to the ht_docs directory with coding that looked like this: RewriteEngine On RewriteCond %{HTTP_HOST} ^customerdomain.com RewriteRule (.*) http://www.customerdomain.com/$1 [R=301,L] But! This didnt work, when i go to the domain without "www" it is supposed to redirect to the with "www" domain, yes? Can any offer help as to why? I have also tried to place a 301 redirect from a page - www.customerdomain.com/home.htm to redirect to www.customerdomain.com/. I used the following code in the .htaccess file: redirect 301 home.htm http://customerdomain.com/ But! This didnt work either! Any help pleeeease!!!!!????
__________________
Latest Blog Post: Google Consultant - Should this Job Title be Allowed? - Matt Inertia's SEO Blog - SEOers.org "Carpe diem, seize the day boys, make your lives extraordinary" - Dead Poets Society |
|
||||
|
|
|
||||
|
There is a lot of literature online that ive been reading over the last few weeks. I have taken example coding from these articles and added my own URLs but the redirect still doesnt work. Is there something fundamental which im missing?
__________________
Latest Blog Post: Google Consultant - Should this Job Title be Allowed? - Matt Inertia's SEO Blog - SEOers.org "Carpe diem, seize the day boys, make your lives extraordinary" - Dead Poets Society |
|
||||
|
Sometimes it can be done in the Cpanel or whatever panel you have. If that is not possible, reread the tutorials above.
Have you tried this more specific search: mod_rewrite site:www dot apache dot org Here is one hit: ApacheModProxy Scroll down to the heading: A more complex example: mod rewrite
__________________
Mini Network:: Financial information at your fingertips Learn object oriented programming where it started Last edited by kgun; 11-16-2007 at 09:49 AM. |
![]() |
|
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| How to do a mod_rewrite? | watto | Web Programming Discussion Forum | 2 | 06-02-2007 01:17 PM |
| mod_rewrite not rewriting | wige | Web Programming Discussion Forum | 4 | 04-25-2007 08:32 PM |
| Mod_rewrite for Google - Yes? or No..... | Mellco | Search Engine Optimization Forum | 5 | 11-29-2005 05:14 PM |
| mod_rewrite | watto | Services for Sale/Hire | 0 | 11-08-2005 08:47 PM |
| mod_rewrite, .htaccess and the root directory problem | PhilC | Web Programming Discussion Forum | 0 | 02-17-2004 03:30 PM |
|
WebProWorld |
Advertise |
Contact Us |
About |
Forum Rules |
MVP's |
Archive |
Newsletter Archive |
Top |
WebProNews
WebProWorld is an iEntry, Inc. ® site - © 2009 All Rights Reserved Privacy Policy and Legal iEntry, Inc. 2549 Richmond Rd. Lexington KY, 40509 |