creating subdomains... cPanel API?

bcamp1973

Registered
Apr 2, 2007
3
0
151
Hello! First post for me :) Hopefully i learn lots! Anyway...

My ISP provides cPanel for our admin tool (I love it!). I'm building a web app (PHP/MySQL) and I would like to create subdomains on a per user basis. The catch is I'd like to do it dynamically so I don't have to touch the app each time a user registers. Is this possible? Is there an API i can plug into? My ISP directed me here to ask the question then told me to let them know if there's anything they can do on their end to make it happen. Obviously I don't want to create any security issues for them, but making this happen would be a big help for my goals. Any suggestions?

Cheers,
B
 

Spiral

BANNED
Jun 24, 2005
2,020
8
193
Yes there is an API you can use to interface your own scripts and programs to Cpanel ...

/usr/local/cpanel/Cpanel/Accounting.php.inc
 

bcamp1973

Registered
Apr 2, 2007
3
0
151
Your need is like, when a user registers, a subdomain of his choice should be created?
Bingo! That's exactly what i'm trying for. I want the user to feel as though they have their own "personal" domain. This is becoming pretty popular with other sites (37signals.com products for example).
 

bcamp1973

Registered
Apr 2, 2007
3
0
151
the path mentioned by spiral isn't accessible by users of my ISP as it's at the root level. does anyone else know of any alternatives?