I have actually done just this with a website of mine...
Best way I found was to use mod_rewrite which will require you to have
apache. If you are are able to do that then just add a file called
..htaccess to your root and in that do:
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule (.*) /index.cfm?username=$1 [L]
J.J.
On 10/15/07, Jessica Kennedy <[EMAIL PROTECTED]> wrote:
> Hi, I am working on a site for a MLM company that wants each person who
> signs up with the company to have their own replicated website. The
> replicated site is really no more than each person having a separate URL
> that is defined by the username they put in when they sign up-
> everyone's site is exactly the same otherwise. For example, if I signed up
> for
> the program with a username of "jessica" my replicated website's
> address would be" "http://www.sample.com/jessica".
>
> I do not want to have to create a separate folder & index page for each
> & every person who signs up, because that seems like it would be kind
> of ridiculous & waste a lot of space, so how can I (firstly) trick the
> server into believing there is a separate page for each person even
> without a folder with their username existing in my directory?
>
> Second, and I guess this question could be answered by the first, how
> can I get that username to be pulled from the URL for use in dynamic
> queries and the like.
>
> -More or less, I am just wanting to somehow convert a query string such
> as "http://www.sample.com?username=jessica" into the more
> user-friendly "http://www.sample.com/jessica".
>
> I think i am making this harder than it really is.. hopefully I have
> made this clear enough to understand, and any help would be greatly
> appreciated! Thanks!!
>
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Check out the new features and enhancements in the
latest product release - download the "What's New PDF" now
http://download.macromedia.com/pub/labs/coldfusion/cf8_beta_whatsnew_052907.pdf
Archive:
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:291175
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe:
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4