1

For Facebook and for Google i found this solution..

<script type="text/javascript">
 $(document).ajaxComplete(function(){
 try{
    FB.XFBML.parse(); 
    gapi.plusone.go(); 
 }catch(ex){}
 });
</script>

but not for tumblr. Does anybody know if there is any solution? Tubmlr-post-button is implemented like this:

<a class="tumblr-share-button" data-href="http://www.xy.ch/news_entries/<?    php echo "{$row['title']}.html" ?>" data-content="http://www.xy.ch/news_entries/<?php echo "{$row['title']}.html" ?>" data-color="blue" data-notes="right" href="https://embed.tumblr.com/share"></a>

Thanks M

Mischu
  • 95
  • 1
  • 7
  • Tumblr support told me that they don't have time to look at problems like this :( – Mischu Oct 31 '15 at 10:44
  • `$( "div" ).html( 'button code here' );`? – u_mulder Oct 31 '15 at 11:00
  • Thank you for your post. I have taken now the buttons from sharethis.com. With the command "stButtons.locateElements()" -> http://stackoverflow.com/questions/7289021/how-to-dynamically-create-share-this-buttons-with-a-custom-urls-with-a-javascr the buttons are showing up after ajax call. – Mischu Nov 02 '15 at 18:42

1 Answers1

0

I had to find another solution (because i have another use case) and worked out this:

<img src='http://www.mywebsite.com/share_list.png' data-pin-no-hover="true" class="share_buttons_img" usemap='#share_buttons' />
<map name='share_buttons'>
  <area shape='circle' coords='78,21,13,80' href="#" title="Share on Facebook" onclick="popUp=window.open('https://www.facebook.com/sharer/sharer.php?u=www.mywebsite.com/news/<?php echo "{$row['image_title']}.html" ?>','popupwindow', 'scrollbars=yes,width=500,height=400');popUp.focus();return false;" >             
  <area shape='circle' coords='116,21,13,80' href="#" title="Share on Tumblr" onclick="popUp=window.open('http://tumblr.com/widgets/share/tool?canonicalUrl=http://www.mywebsite.com/news/<?php echo "{$row['image_title']}.html" ?>','popupwindow', 'scrollbars=yes,width=500,height=400');popUp.focus();return false;" >
  <area shape='circle' coords='153,21,13,80' href="#" title="Share on Google+" onclick="popUp=window.open('https://plus.google.com/share?url=www.mywebsite.com/news/<?php echo "{$row['image_title']}.html" ?>','popupwindow', 'scrollbars=yes,width=500,height=400');popUp.focus();return false;" >
</map>
Mischu
  • 95
  • 1
  • 7