xpanel/epp-bundle 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

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

xpanel/epp-bundle

Composer 安装命令:

composer require xpanel/epp-bundle

包简介

A Symfony Bundle to wrap the EPP connection functionality.

关键字:

README 文档

README

A Symfony Bundle to wrap the EPP connection functionality in a more "classy" way.

Latest Stable Version Total Downloads Latest Unstable Version License Monthly Downloads Daily Downloads composer.lock

Installation

Step 1: Install the Bundle

Require the Bundle with composer:

$ composer require xpanel/epp-bundle

Step 2: Enable the Bundle

Register the bundle in AppKernel:

<?php
// app/AppKernel.php

public function registerBundles()
{
    $bundles = [
        // ...
        new Xpanel\Bundle\EppBundle\XpanelEppBundle(),
    ];
}

Usage

<?php

use Xpanel\Bundle\EppBundle\Exception\EppException;

public function indexAction()
{
    //...

    try {
        $epp = $this->container->get('xpanel_epp');

        $info = array(
            'host' => 'epp.xpanel.com',
            'port' => 700,
            'timeout' => 30,
            'verify_peer' => false,
            'cafile' => '/etc/pki/tls/certs/ca-bundle.crt',
            'local_cert' => '/etc/pki/tls/certs/cert.crt',
            'local_pk' => '/etc/pki/tls/private/private.key',
            'passphrase' => 'XPanel.Online',
            'allow_self_signed' => true
        );
        $epp->connect($info);


        $epp->login(array(
            'clID' => 'Client123',
            'pw' => 'Pass-W0rd',
            'prefix' => 'XP'
        ));


        $checkparams = array(
            'domains' => array('test1.xy','test2.xy')
        );
        $domainCheck = $epp->domainCheck($checkparams);


        $infoparams = array(
            'domainname' => 'test1.xy',
            'authInfoPw' => 'aA1+XPanel+EPP'
        );
        $domainInfo = $epp->domainInfo($infoparams);


        $createparams = array(
            'domainname' => 'test1.xy',
            'period' => 2,
            'nss' => array('NS1.XPANEL.NET','NS2.XPANEL.NET'),
            'registrant' => 'XP-1122334455777',
            'contacts' => array(
                'XP-1122334455777' => 'admin',
                'XP-1122334455777' => 'tech',
                'XP-1122334455777' => 'billing'
                ),
            'authInfoPw' => 'aA1+XPanel+EPP'
        );
        $domainCreate = $epp->domainCreate($createparams);

    }

    catch (EppException $e) {
        echo 'Error: ', $e->getMessage();
    }


echo '<pre>';
print_r($domainCheck);
print_r($domainInfo);
print_r($domainCreate);
echo '</pre>';

    //...
}

Questions

Feel free to contact me

made with ♥

统计信息

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

GitHub 信息

  • Stars: 1
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2017-03-27

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固