Comments (10)
回调商品名称中乱码是因为 支付宝使用 GBK 的编码导致直接 print_r 出来会乱码,但不影响验签的。
所以,是否中文和验签成功与否没有关系。
同时,自己亲生实践,商品名称中包含中文是不影响验签的。
感谢您的支持!
同时,如果您线上环境支持 PHP7.0 建议升级至 v2.x 版本,这个版本做了很多优化。包括您说的编码问题。
from pay.
我也是第一次用,包真的超好用。
我再次检查了公钥设置,依然是走的验签失败,由于调起的是 app 支付,所以gateway是不是要填写'app'?
from pay.
验签时不用填的。
请问您开发环境支持 PHP7.0+ 吗?如果支持,方便的话,麻烦直接升级到 2.x 吧。
from pay.
好吧,是PHP7+ 那我重新写一下吧,在laravel的用法和普通的一样吗?
from pay.
可以直接下载 laravel-pay 扩展包。用法基本一样的。
from pay.
好的谢谢
from pay.
@Gilbertat 请问升级后问题解决了吗?
from pay.
@yansongda 还没有换,正准备,如果有问题我会联系你的 😊
from pay.
@yansongda 使用 2.0版本 无法获得sign
$alipay = Pay::alipay()->app($config_order);
return show('1', "请求成功", ['sign' => $alipay]);
输出是这样的
{
"status": "1",
"message": "请求成功",
"data": {
"sign": {
"headers": {}
}
}
}
dd($alipay)则有如下输出
Response {#444
+headers: ResponseHeaderBag {#445
#computedCacheControl: array:2 [
"no-cache" => true
"private" => true
]
#cookies: []
#headerNames: array:2 [
"cache-control" => "Cache-Control"
"date" => "Date"
]
#headers: array:2 [
"cache-control" => array:1 [
0 => "no-cache, private"
]
"date" => array:1 [
0 => "Thu, 28 Dec 2017 10:22:33 GMT"
]
]
#cacheControl: []
}
#content: "app_id=2017090608590288&method=alipay.trade.app.pay&format=JSON&charset=utf-8&sign_type=RSA2&version=1.0&return_url=¬ify_url=http%3A%2F%2Fwww.mitte.cn%2Fapi%2Falipay%2Fnotify×tamp=2017-12-28+18%3A22%3A33&sign=A2xEa6%2FiN2o21kD8PU4Ao95NF05%2BkmarT7wJ9b5RbpjSrvZqm0%2BSYR4hAnIzr9PgDBBQtoGIwujr%2F9eIxg%2Fvj4oyHuSxCF%2FkqBXZhqBqY4B0A%2FzEXOpfg%2BflKBrZDFn5bIUAecTf1vYTNgmHNH%2BRMa95Kb61psWuraBTnJLHXrz40wUm23Oc0ZSLTfT6trJ%2BrRyJa9pFDHG53nVYgBLrdXmVPaL4OmSUxMEALOiV%2FNVamfhPDlMXxbezIkXRRyr1JxC6eiFotnwPuXMsCuDg4Hm7%2BXv%2FHfDjEgmHZBbSGUoq31ByDCD0Yo4Xh%2B1FjA6ddni%2FSqXqcfzVx25p0I8Wlg%3D%3D&biz_content=%7B%22out_trade_no%22%3A15134884178798981%2C%22total_amount%22%3A%221199.00%22%2C%22subject%22%3A%22LIEMOCH%5Cu5229%5Cu9a6c%5Cu8d6b+%5Cu7231%5Cu52d2%5Cu7cfb%5Cu5217+%5Cu8de8%5Cu754c%5Cu5b9a%5Cu5236%5Cu62c9%5Cu6746%5Cu7bb1%22%2C%22product_code%22%3A%22CURITY_PAY%22%7D"
#version: "1.0"
#statusCode: 200
#statusText: "OK"
#charset: null
}
from pay.
麻烦请看文档 https://yansongda.gitbooks.io/pay/
from pay.
Related Issues (20)
- 微信支付异步通知希望增加对签名探测流量的处理 HOT 4
- swoole下message吃数据 直接把steam变为空了 HOT 27
- fpm模式,微信平台公钥证书校验不通过 HOT 6
- 支持下laravel 11的安装
- 支付宝怎么设置密钥模式(非证书模式) HOT 2
- 支付宝扫码支付的二维码不正确 HOT 1
- 换取授权访问令牌 v2版本 插件\Yansongda\Pay\Plugin\Alipay\V2\Member\Authorization\TokenPlugin 参数不能放在biz_content里面
- 关于微信支付配置wechat_public_cert_path的问题 HOT 7
- 支付宝APP支付无法使用 HOT 4
- 疑似通知回调bug
- 3.3版本怎么没有微信红包功能接口? HOT 2
- Missing Wechat Config -- [mch_public_cert_path] HOT 8
- Missing Wechat Config -- [mch_public_cert_path] HOT 2
- AppID不存在,请检查后再试 HOT 6
- 疑似验签失败 throw new InvalidResponseException(Exception::INVALID_RESPONSE_SIGN, '', ['headers' => $message->getHeaders(), 'body' => $body]);
- feat: 支持微信支付-付款码支付v3接口 HOT 1
- 微信h5支付完成后 页面无法跳转,没有跳转到return_url设置的地址 HOT 1
- 通过内置方法获取不到微信证书 HOT 1
- 支付宝预授权,加密总是出错sign有问题 HOT 1
- 容器未找到: `getContainer()` 方法调用失败! 或许你应该先 `setContainer()` HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pay.