Search code examples
phpjavascriptshareaddthissocial-media

Addthis on an image gallery


I'm using addthis.com to share my pictures from an album (just a page with some pictures in it). This is my addThis code:

    <div class="addthis_toolbox addthis_default_style addthis_32x32_style"
    addthis:url="<?php echo HTTP; ?>album.php?id=<?php echo $_GET['id']; ?>"
    http://lasala-gastrobar.be/album.php?id=27
    addthis:title="An Example Title"
    addthis:description="An Example Description"> 

    <a class="addthis_button_facebook"></a>
    <a class="addthis_button_print"></a>
    <a class="addthis_button_email"></a>

I have this code for every image in my album, and the javascript at the bottom.
Now when I share on facebook, it shares all the images, but I want to be able to share one 1 image at a time.
Same when I click print, only print that 1 picture, not the rest.


Solution

  • got it: the link has to go to a separate page showing only 1 image with correct tags in the head