Forum Moderators: phranque

Message Too Old, No Replies

New to *ix, need a little help

rewriting subdirectories into subdomains

         

Tomale

6:06 pm on Mar 11, 2006 (gmt 0)

10+ Year Member



Hello All…

Please do excuse my ignorance here as I am not a technically oriented individual and new to the *ix world. I have a PHP script that dynamically generates pages for my products/items. I would like to make my site a little more SEO friendly, especially my URLs. I was told that I should consider using “mod rewrite” to accomplish what I am trying to do. I am also a little confused about the .htaccess and the httpd config files. Specifically where I should make the changes.

What I have is:

www.abc.com/cows/brown-cows.html
and
www.abc.com/horses/rodeo-horses.html

What I would like is:

Cows.abc.com/brown-cows.html
and
Horses.abc.com/rodeo-horses.html

What would it entail to accomplish this? What syntax would I need to include in which files?

Thanks for your time and sorry for my ignorance.
Frank

jdMorgan

6:34 pm on Mar 12, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Frank,

Welcome to WebmasterWorld!

The discussion in post #2 of this recent thread [webmasterworld.com], while not addressed to your exact problem, is similar enough at the procedural level to get you started.

After that, it's a matter of using mod_rewrite to 'map' subdomain requests to their respective subdirectories -- another subject we've covered in-depth [google.com] here.

Jim

Tomale

3:07 am on Mar 13, 2006 (gmt 0)

10+ Year Member



thanks jim ... :)