The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

listaccts api search User by domain

Discussion in 'cPanel Developers' started by Renata Dias, May 27, 2016.

Tags:
  1. Renata Dias

    Renata Dias Registered

    Joined:
    May 27, 2016
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Brazil
    cPanel Access Level:
    Root Administrator
    Please can someone help me?
    how to search the User by domain

    example:

    Code:
    $domain = 'mydomain.com';
    
    $accounts = $whm->listaccts($domain);
    
            foreach ($accounts as $ac){
                  $userCp = $ac["user"];
            }
    
            echo $userCp;
    I've tried, but it does not work.

    Thanks,
    Renata
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,723
    Likes Received:
    660
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
Loading...

Share This Page