我在这里从 github 下载了示例(https://github.com/facebook/credits-api-sample)
结束测试。但发生错误。
*Error message returned from Facebook:
1383004
Order::update_order called with invalid state transition:3 -> 0*
我的问题是什么?
我在这里从 github 下载了示例(https://github.com/facebook/credits-api-sample)
结束测试。但发生错误。
*Error message returned from Facebook:
1383004
Order::update_order called with invalid state transition:3 -> 0*
我的问题是什么?
解决了。
我需要更改迁移“signed_request for Canvas”,在https://developers.facebook.com/apps/高级选项卡上确认。
示例代码有错误。
函数 parse_signed_request 的部分
$expected_sig = hash_hmac('sha256', $payload, $secret, $raw = true);
if ($sig !== $expected_sig) {
error_log('Bad Signed JSON signature!');
return null;
}
那里发生错误。我认为代码并不重要,代码只是为了检查。所以我设置了代码注释。
它奏效了!!