Changeset 31059
- Timestamp:
- Mar 26, 2015, 12:54:51 AM (10 years ago)
- Location:
- extensions/ShareThis
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/ShareThis/changelog.txt
r31054 r31059 15 15 16 16 === Changelog === 17 version 1.0.2 18 + Corrected PayPal link for "Donate" link in admin area 19 - Fixed issue with VideoJS plugin when image derivative information is empty/missing. Post to Facebook would be made without image reference 20 17 21 version 1.0.1 18 22 + Added Facebook <meta property="og:.. support -
extensions/ShareThis/main.inc.php
r31054 r31059 2 2 /* 3 3 Plugin Name: ShareThis 4 Version: 1.0. 14 Version: 1.0.2 5 5 Description: Add "Share This" functionality to your site 6 6 //Plugin URI: http://piwigo.org/ext/extension_view.php?eid=543 … … 15 15 // +-----------------------------------------------------------------------+ 16 16 17 define('SHARETHIS_VERSION', '1.0. 1');17 define('SHARETHIS_VERSION', '1.0.2'); 18 18 define('SHARETHIS_ID', basename(dirname(__FILE__))); 19 19 define('SHARETHIS_PATH' , PHPWG_PLUGINS_PATH . SHARETHIS_ID . '/'); … … 82 82 83 83 function sharethis_get_tab_metadata($metadata) { 84 85 84 // pinterest &media=<logo> 86 85 87 86 $url = '{$CUR_PAGE|escape:\'url\'}'; 88 $image = '{ $U_HOME}/{$current.selected_derivative->get_url()|escape:\'url\'}';87 $image = '{if $current.selected_derivative}{$U_HOME}/{$current.selected_derivative->get_url()|escape:\'url\'}{else}{/if}'; 89 88 $title = '{$PAGE_TITLE|escape:\'url\'}'; 90 89 $content = '{$CONTENT_DESCRIPTION|urlencode}'; 90 91 91 92 92 93 $metadata[] = array( … … 99 100 . '<meta property="og:type" content="article">{"\n"}' 100 101 . '<meta property="og:url" content="{$CUR_PAGE}">{"\n"}' 101 . ' <meta property="og:image" content="{$U_HOME}/{$current.selected_derivative->get_url()}">{"\n"}'102 . '{if $current.selected_derivative}<meta property="og:image" content="{$U_HOME}/{$current.selected_derivative->get_url()}">{"\n"}{/if}' 102 103 . '{/html_head}' 103 . '<a href="http://www.facebook.com/sharer/sharer.php?p[title]=' . $title . '&p[url]=' . $url . '&p[images][0]=' . $image . '&p[summary]=' . $content . '" onclick="window.open(this.href, \'\', \'toolbar=0,status=0,width=700,height=500\'); return false;" title="{\'Share on Facebook\'|@translate}" target="_blank"><i class="fa fa-facebook-square"></i> <span>{\'Facebook\'|@translate}</span></a>{/if}' 104 105 104 . '<a href="http://www.facebook.com/sharer/sharer.php?p[title]=' . $title . '&p[url]=' . $url . '{if $current.selected_derivative}&p[images][0]=' . $image . '{/if}&p[summary]=' . $content . '" onclick="window.open(this.href, \'\', \'toolbar=0,status=0,width=700,height=500\'); return false;" title="{\'Share on Facebook\'|@translate}" target="_blank"><i class="fa fa-facebook-square"></i> <span>{\'Facebook\'|@translate}</span></a>{/if}' 106 105 . '{if $sharethis_pinterest}<a href="http://pinterest.com/pin/create/button/?url=' . $url . '" title="{\'Share on Pinterest\'|@translate}" target="_blank"><i class="fa fa-pinterest"></i> <span>{\'Pinterest\'|@translate}</span></a>{/if}' 107 106 . '{if $sharethis_twitter}<a href="https://twitter.com/intent/tweet?text=' . $title . '&url=' . $url .'" title="{\'Share on Twitter\'|@translate}" target="_blank"><i class="fa fa-twitter"></i> <span>{\'Twitter\'|@translate}</span></a>{/if}' … … 111 110 "no_overlay" => TRUE 112 111 ); 113 114 112 return $metadata; 115 113 } -
extensions/ShareThis/template/admin.tpl
r31053 r31059 8 8 <li><a href="http://piwigo.org/forum/viewtopic.php?id=158356" target="_blank">{'Support'|@translate}</a> | </li> 9 9 <li><a title="Follow me on Twitter" href="http://twitter.com/greydragon_th" target="_blank">{'Follow'|@translate}</a> | </li> 10 <li><a href="https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick& amp;hosted_button_id=9MWBSVJMWMJEU" target="_blank">{'Coffee Fund'|@translate}</a> | </li>10 <li><a href="https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=GYVNZCNDMSD58" target="_blank">{'Coffee Fund'|@translate}</a> | </li> 11 11 <li><a href="http://piwigo.org/ext/extension_view.php?eid=793" onclick="return false" target="_blank">{'Download'|@translate}</a></li> 12 12 </ul>
Note: See TracChangeset
for help on using the changeset viewer.