#1 (permalink)  
Old 01-10-2008, 03:33 PM
Registered User
 
Join Date: Feb 2007
Posts: 8
devonblzx is on a distinguished road
Run script on Domain/Sub-domain creation.

I am using my own mod_fcgid build with a wrapper so I can execute php scripts on a per-user basis and add a custom phpini if needed.

Now, since it uses a wrapper on a per-user basis, I need to have a file in the public_html directory in order for it to run properly.

So how can I run a script when a new domain or sub-domain is created? I tried searching the forum without luck, anyone have experience with doing this?

(The script I'm going to run is just going to copy the wrapper to the new public_html directory and chown/chmod it to the correct permissions)

Thanks in advance!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 01-10-2008, 04:07 PM
cPanelDavidG's Avatar
cPanel Technical Sales
 
Join Date: Nov 2006
Location: Houston, TX
Posts: 7,995
cPanelDavidG is on a distinguished road
If this is going to be on a per-user basis rather than a per-domain/subdomain basis, you can insert your hook code into /scripts/postwwwacct

Details on how to do this are available at: http://www.cpanel.net/support/docs/hooks.htm

If you wish to have a hook for any domain/sub-domain creation, you may wish to refer to this document on how to set up hooks for these functions:

/usr/local/cpanel/hooks/README
__________________
Want our technical analysts to login to your server to assist you? You can contact our technical analysts at: http://tickets.cPanel.net/submit
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 09-30-2008, 08:49 AM
Registered User
 
Join Date: Oct 2003
Posts: 124
hekri
The same question how to do that hook?

When user add subdomain or addon domain we must put file to the new domain (subdomain) folder. php.ini for that domain...
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -5. The time now is 08:09 AM.


Powered by vBulletin® Version 3.8.2
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
© cPanel Inc