是否可以在不发布的情况下将照片上传到粉丝专页相册?

2022-11-29php开发问题
1

本文介绍了是否可以在不发布的情况下将照片上传到粉丝专页相册?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

问题描述

在我的粉丝专页上 我添加了我的小应用程序,这使得粉丝可以将照片上传到此粉丝专页的特殊相册.

Here on my fanpage I've added my small app, that makes it possible, that fans can upload photos to a special photo album of this fanpage.

这是可能的,因为我使用了粉丝专页管理员权限(manage_pages、publish_stream 和 offline_access").

It's possible, cuz I use a fanpage admin permission ("manage_pages, publish_stream and offline_access").

但是现在 - 每次有人使用这个应用程序时,我都会在我的粉丝专页上收到一个照片发布新闻提要.如何将照片添加到粉丝专页而不将其发布到新闻流?

But now - everytime someone uses this app, I get a photo publish news feed on my fanpage. How can I add a photo to a fanpage WITHOUT publish it to the newsstream?

实际上我发布的 php 代码如下:

Actually my publish php code looks like:

<?php
  $post_data = array(
    'image' => ('@' . realpath($photo)),
    'message' => $msg)
  );

  $facebook->setAccessToken(_FANPAGE_ACCESS_TOKEN);
  $data = $facebook->api('/'. _ALBUM_ID . '/photos', 'post', $post_data);
?>

当我使用我的粉丝专页管理员帐户删除publish_stream"权限时 - 会出现一个有趣"的错误.上传的照片不会出现在相册中,也不会出现在新闻流中.但是它在照片条中,您可以在其中看到所有新照片,当您单击它时,它将与所有上传的照片排成一排……看起来,它位于隐藏"相册中的某个地方.

When I remove the "publish_stream" permission with my fanpage admin account - there will appear a 'funny' bug. The uploaded photo won't show up in the photo album and not in the news stream. But it is in the photo-strip where you see all new photos and when you click on it, it will be in a row with all those uploaded photos... it looks like, that it is somewhere in a 'hidden' photoalbum.

那么有没有人知道如何在图形 API 上发布照片而不将其发布到新闻流?

提前致谢,尤里克

推荐答案

我找到了解决方案!文档中没有提到它 - 如果您在通过 Graph API 上传照片时不想发布提要,请设置以下参数:no_story=1

I got the solution! Nowhere in the docs is it mentioned - if you don't want post a feed when you upload a photo via Graph API set following parameter: no_story=1

此信息更早在此处:http://developers.facebook.com/文档/参考/api/照片/

但不知何故它从这个文档中消失了.:(

But somehow it disappeard from this doc. :(

来源:我可以上传照片但是没有在 Facebook 上发布到墙上?

如何联系 FB 以便他们添加这个非常重要的信息?

How to contact FB so that they add this VERY important info?

这篇关于是否可以在不发布的情况下将照片上传到粉丝专页相册?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

The End

相关推荐

PHP实现DeepL翻译API调用
DeepL的翻译效果还是很强大的,如果我们要用php实现DeepL翻译调用,该怎么办呢?以下是代码示例,希望能够帮到需要的朋友。 在这里需要注意,这个DeepL的账户和api申请比较难,不支持中国大陆申请,需要拥有香港或者海外信用卡才行,没账号的话,目前某宝可以...
2025-08-20 php开发问题
168

PHP通过phpspreadsheet导入Excel日期数据处理方法
PHP通过phpspreadsheet导入Excel日期,导入系统后,全部变为了4开头的几位数字,这是为什么呢?原因很简单,将Excel的时间设置问文本,我们就能看到该日期本来的数值,上图对应的数值为: 要怎么解决呢?进行数据转换就行,这里可以封装方法,或者用第三方的...
2024-10-23 php开发问题
287

mediatemple - 无法使用 codeigniter 发送电子邮件
mediatemple - can#39;t send email using codeigniter(mediatemple - 无法使用 codeigniter 发送电子邮件)...
2024-08-23 php开发问题
11

Laravel Gmail 配置错误
Laravel Gmail Configuration Error(Laravel Gmail 配置错误)...
2024-08-23 php开发问题
16

将 PHPMailer 用于 SMTP 的问题
Problem with using PHPMailer for SMTP(将 PHPMailer 用于 SMTP 的问题)...
2024-08-23 php开发问题
4

关于如何在 GoDaddy 服务器中使用 PHPMailer 设置 SMTP 的问题
Issue on how to setup SMTP using PHPMailer in GoDaddy server(关于如何在 GoDaddy 服务器中使用 PHPMailer 设置 SMTP 的问题)...
2024-08-23 php开发问题
17