承接 dpsoft/zibal 相关项目开发

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

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

dpsoft/zibal

Composer 安装命令:

composer require dpsoft/zibal

包简介

Zibal online payment - درگاه پرداخت آسان پرداخت به زبان PHP

README 文档

README

Latest Version on Packagist Total Downloads

Installation

You can install the package via composer:

composer require dpsoft/zibal

Usage

copy sample directory to server. Open request.php in browser and bala balah ...

Request

try {
    $zibal = new \Dpsoft\Zibal\Zibal($merchant);
    $result = $zibal->request($callbackUrl,$amount);
    //save amount and invoice id to forther use
    $_SESSION['amount']=$amount;
    $_SESSION['token']=$result['token'];

    $zibal->redirectToBank();
    exit();
}catch (Throwable $exception){
    echo $exception->getMessage();
}

Response

try {
    $zibal = new \Dpsoft\Zibal\Zibal($merchant);
    $result = $zibal->verify($_SESSION['amount'],$_SESSION['token']);
    //save result. The keys are: card_number,transaction_id and token for example $result['token']
    echo "Successfull transaction.";
}catch (Throwable $exception){
    echo "Error in transaction: ";
}

Testing

composer test

Security

If you discover any security related issues, please email info@dpsoft.ir instead of using the issue tracker.

Credits

License

The MIT License (MIT). Please see License File for more information.

统计信息

  • 总下载量: 1.47k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 3
  • 点击次数: 4
  • 依赖项目数: 1
  • 推荐数: 0

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2020-07-07

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固