承接 previewict/cpanel-php-lib 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

previewict/cpanel-php-lib

Composer 安装命令:

composer require previewict/cpanel-php-lib

包简介

cPanel PHP Library for managing WHM & cPanel from any PHP application. Easy to use. Install with Composer and start using it.

README 文档

README

cPanel PHP Library for managing WHM & cPanel from any PHP application. Easy to use. Install with Composer and start using it.

#####Installation Install it via Composer

sudo composer install

copy and paste config.sample and rename it to config.php. Now replace all the variable in config file with your server url, root username and password.

And you are done!

#####cPanel/WHM SDK Documentation To use it you have to know the original cPanel/WHM documentation. All the commands and parameters are explained there. Based on their documentation suppose you need to call a url to get an account summery with this /json-api/accountsummary?api.version=1&user=username url.

To call that url you have to write $request->build('accountsummary', array('params' => array('user' => 'username', 'api.version' => 1))). First parameter will be command name and second parameter will hold an array where you can pass additional url parameter with array('params' => array()) params key.

#####Usage To get the list of Packages from your WHM.

$request = new \CpanelPhp\Cpanel\Request(WHMURL, WHMPORT);
$response = $request->build('listpkgs')->data;
print_r($response);

Note: if you face any problem please create issue in this repository

统计信息

  • 总下载量: 34
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 6
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 5
  • Watchers: 3
  • Forks: 5
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2015-05-20