Home >Backend Development >PHP Tutorial >关于使用七牛pfop的返回处理结果的问题

关于使用七牛pfop的返回处理结果的问题

WBOY
WBOYOriginal
2016-06-06 20:29:191855browse

请问我在使用七牛的pfop的文档处理的时候,如何把云端转换的结果返回到我指定的URL呢?
我用的phpsdk,以下是我的源码:

<code>$accessKey = '这是key';
$secretKey = '这是key';
$auth = new Auth($accessKey, $secretKey);

$bucket = '这是bucket';
$key = $_POST['key'];


$pipeline = "pdfcov";
$notifyUrl = 'http://www.demo.com/notify/qiniu_doc';
$pfop = new PersistentFop($auth, $bucket, $pipeline);

$fops='yifangyun_preview';
list($id, $err) = $pfop->execute($key, $fops, $notifyUrl);

地址在公网可以访问,是不是我哪里写错了?我查看服务器日志,没有发现七牛的回掉信息啊</code>

回复内容:

请问我在使用七牛的pfop的文档处理的时候,如何把云端转换的结果返回到我指定的URL呢?
我用的phpsdk,以下是我的源码:

<code>$accessKey = '这是key';
$secretKey = '这是key';
$auth = new Auth($accessKey, $secretKey);

$bucket = '这是bucket';
$key = $_POST['key'];


$pipeline = "pdfcov";
$notifyUrl = 'http://www.demo.com/notify/qiniu_doc';
$pfop = new PersistentFop($auth, $bucket, $pipeline);

$fops='yifangyun_preview';
list($id, $err) = $pfop->execute($key, $fops, $notifyUrl);

地址在公网可以访问,是不是我哪里写错了?我查看服务器日志,没有发现七牛的回掉信息啊</code>

https://github.com/rwifeng/qiniudocs/blob/master/docs/php-sdk/sdk/php-sdk-7.0.2/src/Qiniu/Processing/PersistentFop.php#L36

构造函数是这样的,$notifyUrl应该写在new PersistentFop($auth, $bucket, $pipeline)里面的。

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn