PHP Classes

Problem of adding database user in database using cpanel API

Recommend this page to a friend!

      cPanel API  >  All threads  >  Problem of adding database user in...  >  (Un) Subscribe thread alerts  
Subject:Problem of adding database user in...
Summary:Problem of adding database user in database using cpanel API
Messages:1
Author:Amarjeet Kaur
Date:2011-01-07 06:11:51
 

  1. Problem of adding database user in...   Reply   Report abuse  
Picture of Amarjeet Kaur Amarjeet Kaur - 2011-01-07 06:11:51
Hi All,

I have been using the cpanel API of PHP classes to run an auto installation script which used to create the cpanel account and create database and database user and add user to database. Following is my code used for creating the creating user and adding the same to database.

$user_created=$db_user->create($pass_db);


the above method "create" is used to create the database user.

$add_user = $db->adduser('user');

the method "adduser" is used to add database user to database.

Both the above methods were working fine few days ago, but now these are not working. Can anyone please suggest me any solution of this problem?

Thanks,
Amarjeet