Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

create folder and populate with file

Status
Not open for further replies.

derwent

Programmer
Joined
May 5, 2004
Messages
428
Location
GB
I would like registered users to be able to create a little profile of themselves with their own url, however I am trying to keep away from querystring urls such as profile.asp?id=1538365343763

Is it possible to create a folder and then place a default.asp file inside that?

The process is this:

they complete an online form with their info
press submit
a physical folder is created
their profile url is eg. mysite.com/bob/
instead of mysite.com/profile.asp?id=t374637463

Is this possible and if so, are there any tutorial sites offering help?

Thanks folks
 
i dont think u can do away with the profile.asp, but u can do away with the id part of it, use sessions...

Known is handfull, Unknown is worldfull
 
You should be able to do it easily using the FileSystemObject.
 
I want the user to be able to have their own permanent url to be able to give to people hence wanting to do away with the querystring.

neil, do you know any good sites that will help??

thanks folks
 
If you search around the site there should be plenty of info about the FileSystemObject. You could use this to implement your first suggestion which would do away with the necessity for the querystring.
 
i dont think thats possible (showing a different url while accessing an ASP page)...

Known is handfull, Unknown is worldfull
 
You don't need to show a different URL, you can create the relevant sub-directory and asp page that is specific to the users profile.
 
Ouch, that makes it a pain when it comes time to change anything.

My suggestion, if your going to go with physical directories for users, is to put an index.asp or default.asp page in there but make it load everything from includes that are in the parent path, that way if you need to change something you can still change it in one spot, but you still get your physical directories.

has good references for all the FileSystemObjects, just hit the ASP link and look for it in the right column.

-T

01000111 01101111 01110100 00100000 01000011 01101111 01100110 01100110 01100101 01100101 00111111
Help, the rampaging, spear-waving, rabid network gnomes are after me!
 
tarwn got it on the head there...

i've been doing this for ages with a self-replicating index.asp page i use site wide... if special variables are used to "get" to a folder, those are written as value assignments into the creation of the index.asp in the subfolder via FSO.

i can post some sample code for this but it's pretty simple once you get the fso in place and the folder created.

[thumbsup2]DreX
aKa - Robert
 
Thanks folks, I`ll look at the FSO and see if I can figure out what I need to do.

I guess the header, footer, etc would be includes and the changing content would link back to the database pulling out the unique content for each page.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top