how can i create virtual folders in server automatically...

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
B.Murali Krishna
Forum Commoner
Posts: 28
Joined: Fri May 12, 2006 2:05 am
Location: Hyderabad,India
Contact:

how can i create virtual folders in server automatically...

Post by B.Murali Krishna »

i need to generate vitual folder through php program in apache server, by which i can generate subdomains
.
for ex: if i click on the links of my site

link1 link12 ---------------------

like that, when i click on this link generally we will generate folder naming link1 by mkdir() function in server
then the url will be sitename.com/link1/

but i need to generate the url like: http://link1.sitename.com

ie virtual folder, so how can i create those by program, in apache server,

i hope i have given u the clear picture of my doubt,

i hope the best from u,
Last edited by B.Murali Krishna on Tue Jul 04, 2006 2:02 am, edited 3 times in total.
jmut
Forum Regular
Posts: 945
Joined: Tue Jul 05, 2005 3:54 am
Location: Sofia, Bulgaria
Contact:

Post by jmut »

You should be more specific at your question.
Do you know how to create them without using application (by hand)?
What server are you using?
You said you have an application (maybe we will have to do a snippet from it at some point).
User avatar
Jenk
DevNet Master
Posts: 3587
Joined: Mon Sep 19, 2005 6:24 am
Location: London

Post by Jenk »

after a quick google, I doubt this is possible as Apache will need to be restarted - vhosts need to be specified in httpd.conf.
Post Reply