ecpay / ecpayaio_php Goto Github PK
View Code? Open in Web Editor NEW綠界ECPay 全方位(All In One)金流介接 PHP版
綠界ECPay 全方位(All In One)金流介接 PHP版
PHP Version: PHP 7.4
Example Code:
<?php
require __DIR__ . '/ECPayAIO_PHP/AioSDK/sdk/ECPay.Payment.Integration.php';
Error Message:
PHP Fatal error: Class ECPay_GooglePay contains 2 abstract methods and must therefore be declared abstract or implement the remaining methods (ECPay_Verification::check_goods, ECPay_Verification::check_extend_string) in /tmp/ECPayAIO_PHP/AioSDK/sdk/ECPay.Payment.Integration.php on line 1578
Fatal error: Class ECPay_GooglePay contains 2 abstract methods and must therefore be declared abstract or implement the remaining methods (ECPay_Verification::check_goods, ECPay_Verification::check_extend_string) in /tmp/ECPayAIO_PHP/AioSDK/sdk/ECPay.Payment.Integration.php on line 1578
ECPay.Logistics.Integration.php
737 $this->ValidatePhoneNumber('ReceiverPhone', $this->PostParams['ReceiverPhone'], 20, true);
738 $this->ValidatePhoneNumber('ReceiverCellPhone', $this->PostParams['ReceiverCellPhone'], 20, true);
Method call uses 4 parameters, but method signature uses 3 parameters.
您好:
希望可以建立composer package, 方便安裝跟管理版本
開立發票中的參數,在文件中載具類別編號分別是 CarrierType 與 CarrierNum,但 SDK 中是 CarruerType 與 CarruerNum,看起來 Carrier 應該是筆誤
範例中的 Items 陣列包含 Key Name Name
Price
Currency
Quantity
ECPayAIO_PHP/AioSDK/example/sample_Credit_CreateOrder.php
Lines 30 to 32 in 5087fb9
SDK 中轉換的方式卻是使用 array 的方法轉為字串
ECPayAIO_PHP/AioSDK/sdk/ECPay.Payment.Integration.php
Lines 1151 to 1158 in 5087fb9
Name
Price
Currency
Quantity
在程式端指定的順序跟範例不一樣時,會造成字串顯示與預期不符
['Name' => 'TEST', 'Price' => 100, 'Quantity' => 1, 'Currency' => '元']
會變成 TEST 100 1 x 0
以上為實作時剛好遇到的問題給個心得,
也希望對剛好有遇到類似問題的開發者有所幫助~
在 ECPay.Logistics.Integration.php 中所使用的正規式規則 /[\^\'`\!@#%&\*\+\\\"<>\|_\[\]]+/
會造成部份中文字元判斷異常,而導致驗證不通過,因為規則中使用了全形@
而導致
最近開立電子發票有時會收到下面問題
6:CustomerIdentifier
12:CustomerIdentifier
想請問是什麼原因造成的
每次補開發票都很辛苦
API文件上載具為Carrier,SDK和Sample Code並未修正還是為Carruer
有時候會出現這個錯誤,Could not resolve host
我DNS該怎麼設定,我是跟digital ocean租的伺服器
在603行的function
第一個參數有預設字串
但是在PHP 8.0中會顯示錯誤
似乎是8.0有刪除部分功能
原本第一個參數是這樣
protected static function HtmlEncode($target = "_self", $arParameters, $ServiceURL, $szCheckMacValue, $paymentButton = '')
改為這樣
protected static function HtmlEncode($target, $arParameters, $ServiceURL, $szCheckMacValue, $paymentButton = '')
就沒有問題了
呼叫CheckOut function也沒問題
您好
在 check_invoiceString 這個 function 中,正規化驗證 CustomerIdentifier 的變數是否有誤
$arParameters
這個變數不屬於這個 function 裡的
是否需要將
改為
if (!preg_match('/^[0-9]{8}$/', $arExtend['CustomerIdentifier'])) {
我發現「ServerReplyURL」並沒有打到我伺服器的行為,我是使用 127.0.0.1 在本地測試的,還是說回傳的不是 POST 是 json 格式呢?
我是在API文件第六點
https://www.ecpay.com.tw/Content/files/ecpay_030.pdf
不管是用POST、GET都不行!好像根本沒打過來一樣
開立發票中有 SpecialTaxType,雖然不是必填,但相較於其他非必填的欄位,在 SDK 中沒有這個欄位
物流的example好歹也加個 readme.md,一支一支點開看半天就過去了
15d1895 的修改會造成手機選超商出現錯誤 call to undefined method EcpayLogistics::IsLegalValue()
在以下的SDK中,沒有對應的版本號,建議建立版本號,可以在第三方整合套件中,有一定程度的幫助
https://github.com/ECPay/ECPayAIO_PHP/blob/master/AioSDK/sdk/ECPay.Payment.Integration.php
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.