英文:
Golang facebook api huandu/facebook Post Description issue
问题
package main
import (
"fmt"
fb "github.com/huandu/facebook"
)
func main() {
res, e := fb.Post("/97876588/feed", fb.Params{
"type": "link",
"name": "test news is here",
"caption": "The caption of a link in the post",
"picture": "http://img.tvguide.dk/tvnyheder/39ecaf74dbfa71c79225705c0d36bb09.jpg",
"link": "http://img.tvguide.dk/tvnyheder/39ecaf74dbfa71c79225705c0d36bb09.jpg",
"description": "hendes lille datter foregik nemlig under helt andre omstændigheder,er Tina Lund.",
"access_token": "access-token",
})
fmt.Println(e)
fmt.Println(res)
}
你好,我正在使用golang的huandu/facebook作为Oath客户端来发布文章,但是描述和名称字段没有被发布,只有状态消息、图片和链接被发布。请帮忙看看问题出在哪里。
英文:
Hi I am using golang huandu/facebook as Oath client to post articles, But the description and name fields does not get posted, only the status message and the image , link get published.. Please help
package main
import (
"fmt"
fb "github.com/huandu/facebook"
)
func main() {
res, e := fb.Post("/97876588/feed", fb.Params{
"type": "link",
"name": "test news is here",
"caption": "The caption of a link in the post ",
"picture": "http://img.tvguide.dk/tvnyheder/39ecaf74dbfa71c79225705c0d36bb09.jpg",
"link":"http://img.tvguide.dk/tvnyheder/39ecaf74dbfa71c79225705c0d36bb09.jpg",
"description":"hendes lille datter foregik nemlig under helt andre omstændigheder,er Tina Lund.",
"access_token": "access-token",
})
fmt.Println(e)
fmt.Println(res)
}
答案1
得分: 1
我发现问题所在,只是因为我链接到了jpeg文件,当放置一个正确的链接时,它就完美地工作了。
英文:
I found the problem , it is just because of i am linking to the jpeg file, when place a proper link it works perfect..
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论