I have cpanel version 11 and i try to auto create email from PHP using this code
<?php
$cpuser = "cpanel_user_name";
$cppass = "cpanel_password";
$euser = "email_user_name";
$epass = "email_password";
$equota = "email_quota";
$domain = "domian.com";
$url = "http://".$cpuser.":".$cppass."@".$domain."2082/frontend/x3/mail/doaddpop.html?email=".$euser."&domain=".$domain."&password=".$epass.""a=".$equota;
if($cpanel = fopen($url, "r"))
{
echo "Success email creation.";
fclose($cpanel);
}
else
{
echo "Failed email creation.";
}
?>
When I run this code I get the result "Success email creation." but when I login to cpanel I not found the new email in the list.
What the wrong ?
<?php
$cpuser = "cpanel_user_name";
$cppass = "cpanel_password";
$euser = "email_user_name";
$epass = "email_password";
$equota = "email_quota";
$domain = "domian.com";
$url = "http://".$cpuser.":".$cppass."@".$domain."2082/frontend/x3/mail/doaddpop.html?email=".$euser."&domain=".$domain."&password=".$epass.""a=".$equota;
if($cpanel = fopen($url, "r"))
{
echo "Success email creation.";
fclose($cpanel);
}
else
{
echo "Failed email creation.";
}
?>
When I run this code I get the result "Success email creation." but when I login to cpanel I not found the new email in the list.
What the wrong ?