facebook feed method link by default adding fb_ref=Default at the end how to remove that

前端 未结 1 1534
自闭症患者
自闭症患者 2021-01-14 09:30

I am using feed method for posting into my facebook wall from my website using asp.net and jquery/javascript initially it works fine but suddenly in the link at the end adde

相关标签:
1条回答
  • 2021-01-14 09:35

    You can resolve this issue via using .htacess by adding this above your current rules will remove everything starting from the &fb_action.

    RewriteRule ^(.*?)&fb_action /$1 [L,R=301]
    

    But this is work around and the correct way is using Share Dialog rather that Feed Dialog.

    The main different between Feed Dialog vs Share Dialog as you can see

    https://developers.facebook.com/docs/sharing/reference/feed-dialog/v2.0 https://developers.facebook.com/docs/sharing/reference/share-dialog

    Feed Dialog:

    You can add the Feed Dialog to your app so people can publish individual stories to their timeline. This includes captions that your app manages and a personal comment from the person sharing the content.

    Share Dialog

    The Share dialog prompts a person to publish an individual story or an Open Graph story to their timeline. This does not require Facebook Login or any extended permissions, so it is the easiest way to enable sharing on web.

    So in you have to use:

    Feed Dialog ==> for Pages you developed so you can change htaccess

    Share Dialog ==> for Pages you can not change it's code

    0 讨论(0)
提交回复
热议问题