Status: solved
Problem:
Whenever I want to share a post with Facebook, then the post will remain attached
[Lnk "https://www.facebook.com/dialog/return/close#_=_" /]
Solution:
The transfer works correctly with window.open (URL). Code see below ..
Something is missing in the meta tags.
Afterwards the URL remains attached
[Lnk "https://www.facebook.com/dialog/return/close#_=_" /]
Solution:
You can push a small javascript-window in between ...
Instead of directly executing the link, pass the link to the function window.open (..)
href="javascript:share_Facebook();"
|
And in the function the link is opened
function share_Facebook() { var myWindow = window.open("@sURL_Sharer_Facebook", "", "top=30px,width=200,height=100"); } |
Code in Asp.Net Core
@{ string sURLRef = Website_Constants.URL_Domain_Base + "/Notes/Details/" + @Model.Note.IDNote; sURLRef = sURLRef + sRef_Part;
string sURL_Sharer_Facebook = "https://www.facebook.com/sharer/sharer.php?u=" + sURLRef; } <a href="javascript:share_Facebook();" title="Share on Facebook. Get Followers to your ID"> <div class="share"> <img src="~/_images/ico/icoFacebook2.png" class="share-img" /></div> </a>
<script> function share_Facebook() { var myWindow = window.open("@sURL_Sharer_Facebook", "", "top=30px,width=200,height=100"); } </script>
|
In asp.net core-> html issue