Thread: Facebook

Results 1 to 1 of 1
  1. #1
    Join Date
    Dec 2007
    Posts
    52
    Plugin Contributions
    0

    Default Facebook

    Hi,

    Site = www dot imaginart dot com dot au

    I've just added the code below to includes/templates/MY TEMPLATE/templates/tpl_product_info_display.php and it seems to have worked fine for most products (e.g. if you go into 'Prints', you will find the 'Share X on Facebook' link). However, I have noticed that no 'Gift Cards' have this link. Why would it not have worked for a whole category? Also, as a side question - would there be a way of editing what is sent across to Facebook? At the moment the ID code is also sent, but it would be nice to stop this.

    Thanks for any help that can be offered.

    Brian

    Code:
    <link rel="image_src" href="<?php echo "http://" . $_SERVER['HTTP_HOST'] . "/shop/" . $products_image_medium; ?>"/>
    <script>function fbs_click() {u=location.href;t=document.title;window.open('http://www.facebook.com/sharer.php?u='+encodeURIComponent(u)+'&t='+encodeURIComponent(t),'sharer','toolbar=0,status=0,width=626,height=436');return false;}</script><style> html .fb_share_link { padding:2px 0 0 20px; height:16px; background:url(http://b.static.ak.fbcdn.net/rsrc.php/zAB5S/hash/4273uaqa.gif) no-repeat top left; }</style><a href="http://www.facebook.com/share.php?u=<?php echo "http://" . $_SERVER['HTTP_HOST'] . $_SERVER['PHP_SELF'] . "?" . $_SERVER['QUERY_STRING'];?>" onclick="return fbs_click()" target="_blank" class="fb_share_link">Share <strong><?php echo $products_name; ?></strong> on Facebook</a>
    Last edited by Brian Flanagan; 1 Mar 2010 at 12:13 PM. Reason: Wrong code.

 

 

Similar Threads

  1. v139h Facebook like addon weird appearance on facebook activity
    By navido in forum General Questions
    Replies: 0
    Last Post: 7 Sep 2014, 06:34 PM
  2. v151 facebook scraper/google linter can't find my urls with Numinix Facebook Like
    By flernebunu in forum All Other Contributions/Addons
    Replies: 1
    Last Post: 20 Mar 2013, 11:25 AM
  3. Facebook share?
    By provida in forum All Other Contributions/Addons
    Replies: 16
    Last Post: 17 Nov 2011, 02:36 PM
  4. Facebook
    By jewellerylounge in forum General Questions
    Replies: 3
    Last Post: 19 Oct 2011, 01:58 PM
  5. facebook link
    By alexdog1805 in forum Basic Configuration
    Replies: 8
    Last Post: 11 Jan 2011, 07:03 PM

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
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR