I'm working in a project with Django and I'm trying to share pages in facebook and twitter
I have problems on facebook, I want to customize the Title and summary shared, to change the text when you share an Index Page and any other page.
I tried using:
<a href='http://www.facebook.com/sharer.php?s=100&
p[title]=TITLE+TEST&
p[summary]=summary&
p[url]=http://{{ request.META.HTTP_HOST }}{{ request.path }}&
p[images][0]=http://whatever.com/media/img/img_facebook.jpg'
target="_blank">
<img src="{{STATIC_URL}}img/ico_facebook_small.png" title="Facebook" alt="Facebook" ></a>
and even adding:
<meta property="og:title" content="My Title" />
The only 2 things I can change is the url showed and the image. Facebook sharer ignores title and summary. I search trough internet the last hour and I didn't find any solution that works for me.
Anyone knows if the facebook sharer isn't working anymore ? is there any solution to custom title and summary ?
Thanks
EDIT
Now I'm using og meta tags, but still have a problem. I want that each page has different titles, and I need to get the title via Javascript (I change the "og:title" content via js) but it seems the change take effect too late, because Facebook only get the part of the title that is static.
I have something like:
<meta property="og:title" content="TitlePage" />
and change the content via js to make like
<meta property="og:title" content="TitlePage SOMETHINGELSE" />
The change takes effect nice and without problems but like I said, facebook doesn't detect that change.
EDIT 2
I've answered my own question because I've found a solution to do the sharing in the old way, but an app is needed to make the code works.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…