Click to See Complete Forum and Search --> : URL Extensions?


xman51
09-12-2005, 01:50 PM
Hello all,

I am writing an ASP/database driven site and I need to be able to have subdomains in my code based on certain member information. For instance if my membership name for the site is "James" then I would need the URL as follows:

www.mywebsite.com/James

And I would need the above URL to point to an asp page...

Does anyone know how I can accomplish this?

Thanks in advance,

Xman51

HaganeNoKokoro
09-12-2005, 02:06 PM
I suppose one way to do it would be to have a directory named after the user, and put code into a page called index.asp (which would, in the absence of other default pages such as index.html, be the default page for the directory).

xman51
09-12-2005, 02:22 PM
that is great!!

Now, how would I create a folder on the server and an index file everytime a new member registers on my site??

HaganeNoKokoro
09-12-2005, 02:33 PM
I guess you'd use the Scripting.FileSystemObject (http://msdn.microsoft.com/library/default.asp?url=/library/en-us/script56/html/jsfsotutor.asp)

buntine
09-12-2005, 09:40 PM
Then use the CreateFolder and CreateTextFile methods.