承接 hans-thomas/zarinpal 相关项目开发

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

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

hans-thomas/zarinpal

Composer 安装命令:

composer require hans-thomas/zarinpal

包简介

transaction request system for zarinpal

README 文档

README

transaction request library for zarinpal

usage

installation

composer require hans-thomas/zarinpal

laravel ready

define these env variables in .env file

merchantID=XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX
sandbox=true
zarinGate=false

then add this to config/services.php

'zarinpal' => [
    'merchantID' => env( 'merchantID', 'XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX' ),
    'zarinGate'  => env( 'zarinGate', false ),
    'sandbox'    => env( 'sandbox', false ),
],

now you can access the zarinpal lib like this:

use Zarinpal\Laravel\Facade\Zarinpal;

$results = Zarinpal::request(
    "example.com/call_back",               //call back url is required
    1000,                                  //amount is required
    'testing',                             //description is required also
    'metadata' => [
        'me@example.com',                  // email is optional
        '09000000000',                     //phone number is optional
    ]
    
);
// save $results['authority'] for verifying step
Zarinpal::redirect(); // redirect to zarinpal

// after that verify transaction by that $results['authority']
Zarinpal::verify(1000,$results['authority']);

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: GPL-2.0-only
  • 更新时间: 2020-12-15

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固