Use a custom 404 page.  You will need to update the 404 error handling in
your server (Apache, IIS, etc) to point to this new page on all 404 errors.

This page will parse the cgi.request_uri string into an array based on the
"/" character.

Do a check in the database for the user which matches the value in the last
position in the array. (or you can do an 'or' check for each of the
positions after the host_name)

If the result is eq 1, then display the agent's website.

If the result is gt 1, then display a 'choice' of which one the user had
intended to type in.

If the result is eq 0, then show your 404 error page.

William

-- 
William E. Seiter
 
Have you ever read a book that changed your life?
Go to: www.winninginthemargins.com
Enter passkey: goldengrove
 
Web Developer 
http://William.Seiter.com

-----Original Message-----
From: Jessica Kennedy [mailto:[EMAIL PROTECTED] 
Sent: Monday, October 15, 2007 12:14 PM
To: CF-Talk
Subject: Creating replicated sites with coldfusion

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!! 



~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
ColdFusion is delivering applications solutions at at top companies 
around the world in government.  Find out how and where now
http://www.adobe.com/cfusion/showcase/index.cfm?event=finder&productID=1522&loc=en_us

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:291173
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

Reply via email to