SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Zealot
    Join Date
    Apr 2013
    Posts
    104
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Question Share product on social media without product image.

    Hi,

    In our e-commerce website we are sharing products on social media like linkedin,twitter,google+ and facebook.

    We want to share product name not product image.

    How disable sharing product image in following code example.

    Any idea?

    Code:
    [1]. Twitter
    
    <a href="http://twitter.com/share" data-url="product-link.php" data-text="{strip}{$product_title|escape:'htmlall'}{/strip}" class="twitter-share-button" data-count="horizontal" data-via="YamTemplates.com">Tweet</a>
    <script type="text/javascript" src="https://platform.twitter.com/widgets.js"></script>
    
    [2]. Google
    
    <!-- Place this tag where you want the share button to render. -->
    <div class="g-plus" data-href="product-link.php"  data-action="share" data-annotation="bubble"></div>
    
    <!-- Place this tag after the last share tag. -->
    <script type="text/javascript">
      (function() {
        var po = document.createElement('script'); po.type = 'text/javascript'; po.async = true;
        po.src = 'https://apis.google.com/js/platform.js';
        var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(po, s);
      })();
    </script>
    
    [3]. Facebook
    
    <div id="fb-root"></div>
    <script>(function(d, s, id) {
      var js, fjs = d.getElementsByTagName(s)[0];
      if (d.getElementById(id)) return;
      js = d.createElement(s); js.id = id;
      js.src = "//connect.facebook.net/en_US/all.js#xfbml=1&appId=25345345345345";
      fjs.parentNode.insertBefore(js, fjs);
    }(document, 'script', 'facebook-jssdk'));</script>
    
    <div class="fb-share-button" data-href="product-link.php" data-type="button_count"></div>
    		
    [4]. Linkedin
    
    <script src="//platform.linkedin.com/in.js" type="text/javascript">
     lang: en_US
    </script>
    <script type="IN/Share" data-url="product-link.php" data-counter="right"></script>
    -Thanks

  2. #2
    Non-Member
    Join Date
    Feb 2014
    Posts
    1
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi,

    I am mary john. Sorry to say but you can't delete image from code. You can request to facebook, twitter and linkedin for delete image. They can delete image.

    Thanks,
    Mary John


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •