Hello, I have been trying many different ways to complete this and I am totally stuck. I can use the cURL in my terminal fine and it does what I want it to do. I am creating a system where I want the people offering the position to have an automatic system in place.
this code works when I add my information,
curl -H'Authorization: cpanel username:U7HMR63FHY282DQZ4H5BIH16JLYSO01M' 'https://example.com:2083/execute/Email/add_pop?email=newuser&password=12345luggage'
The problem I seem to be having is that it is not connecting to the cPanel?
Is this because I am on a shared hosting plan?
If not then what are the parameters I need to add to the new CPANEL() I have tried username, api token and both I.P and Domain names.
$cpanel = new CPANEL(); // Connect to cPanel - only do this once.
// Create the
[email protected] email address.
$new_email = $cpanel->uapi(
'Email', 'add_pop',
array(
'email' => 'user',
'password' => '12345luggage',
'quota' => '0',
'domain' => 'example.com',
'skip_update_db' => '1',
)
);
What am I doing wrong apart from something obvious, I have managed to get everything working how I want in this site apart from this part.
Thank you in advance,
Greg