This PHP script will add email forwarder to cPanel account by using it’s API. It’s pretty simple to call the API using PHP. For this example I’m not gonna use their SDK as it’s only one call, unless you want to call multiple API’s then their SDK is more practical.
You can download the entire script:
Before run this script make sure to change some settings.
/***** *Setting part *Change according to your cPanel settings *****/ $fwd_to_email = "mahadirlabxxx@gmail.com"; //your free email eg: gmail and so on. $fwd_from_email = "madetxx@mahadirlab.com"; //your forwarder email $port = 2082 ; //2082 for unsecured, 2083 for secured but your hosting must support SSL (put https in cpanellogindomain) $cpanelpassword = "yourpass#"; //your cPanel login password $cpanelusername = "xxxx"; //your cPanel username $cpanellogindomain = "http://mahadirlab.com"; //your domain when login to cPanel without port or /cpanel .
WHMCS Hacks – Get Domain TLD List
WHMCS provides various APIs for developer, but recently I need an API to get list of the TLD domain for... more
Download Papago M11 Malaysia & Singapore
Today I had the opportunity to try new Android Papago M11 for Malaysia and Singapore. Overall rating for this new... more
file_get_contents – failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found
I was recently wrote Facebook application using graph API , In this case my application need to update settings in... more
Tutorial How to Root and UnRoot Phone with Android Gingerbread
In this tutorial I will share how to Root and Unroot Android Gingerbread without using Odin or starting the phone... more
Anonymous Hacker Attacked Malaysian Government Portal
Wow... It was very shocked since a group of very well-known Hackers sent their notice to attack Malaysian Government portal... more
MHR Custom Anti Copy (WordPress Plugin)
Do you come here to find the solution for your web contents always being copied by other peoples without your... more
Free Hosting (000webhost) is Scam
Welcome to my new blog.. I have moved to new paid domain. My previous blog which was hosted on free... more

