Community Forums
Connect with us on LinkedIn
+ Reply to Thread
Results 1 to 5 of 5
  1. #1
    Registered User
    Join Date
    Feb 2008
    Posts
    4

    Default Create text file when add / remove domain.

    Hi everyone,

    I need create a text file when a domain is created and removed.
    domaintest.com created
    domaintest2.com removed
    domaintest3.com removed
    domaintest123.com created

    I edited the file /scripts/wwwacct, but not worked.
    system("echo $domain created >> /root/log.txt");

    File /scripts/killacct:
    system("echo $domain removed >> /root/log.txt");


    My cpanel verion is 11.
    I had this in old cpanel version, but cpanel 11, I can´t.

    Please, help-me.

    Joao

  2. #2
    Registered User
    Join Date
    Feb 2008
    Posts
    4

    Default

    Hi,

    Please, help-me.
    It is very important.

    Thank you

  3. #3
    Technical Product Specialist cPanelDavidG's Avatar
    Join Date
    Nov 2006
    Location
    Houston, TX
    Posts
    11,189
    cPanel/Enkompass Access Level

    Root Administrator

    Default

    Quote Originally Posted by joaosavioli View Post
    Hi,

    Please, help-me.
    It is very important.

    Thank you
    Instead of modifying /scripts/wwwacct, in cPanel 11 you should modify /scripts/postwwwacct for accounts created (/scripts/postkillacct for accounts terminated). Documentation on this is available at:

    http://www.cpanel.net/support/docs/hooks.htm

  4. #4
    Registered User
    Join Date
    Feb 2008
    Posts
    4

    Default

    Hi David!

    Thank you

    But, I can´t locate this file.
    Look:
    [root@linux]# cat /scripts/postkillacct
    cat: /scripts/postkillacct: No such file or directory

    [root@linux]# cat /scripts/postkillacct
    cat: /scripts/postkillacct: No such file or directory

    Where are these files?

    Thank you!
    Joao

  5. #5
    cPanel Development cpanelkenneth's Avatar
    Join Date
    Apr 2006
    Posts
    3,782
    cPanel/Enkompass Access Level

    Root Administrator

    Default

    YOu have to create those files and make them executable:

    Code:
    touch cat /scripts/postkillacct
    chmod +x cat /scripts/postkillacct

Similar Threads & Tags
Similar threads

  1. Removing Add-on domain doesn't completely remove subdomains...
    By harikaram in forum cPanel and WHM Discussions
    Replies: 4
    Last Post: 03-15-2010, 05:34 PM
  2. Problems to remove an add domain
    By karatekid in forum cPanel and WHM Discussions
    Replies: 1
    Last Post: 06-05-2009, 10:12 AM
  3. Inability to Remove Add-on Domain
    By Solokron in forum cPanel and WHM Discussions
    Replies: 1
    Last Post: 10-20-2004, 12:12 AM
  4. Deleting an add-on domain doesn't remove domain DNS entry
    By MattF in forum cPanel and WHM Discussions
    Replies: 0
    Last Post: 10-17-2002, 09:17 PM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube