Difference between revisions of "ShareThis"

From GLMWiki
Jump to: navigation, search
(Created page with "While '''we should NOT be using this plugin''', for the plugin has been broken for months by admittance of the plugin creator, should there be no way around it, this is how to...")
 
Line 11: Line 11:
 
}</pre>  
 
}</pre>  
  
then for the final ShareThis menu button: <pre>
+
then for the ShareThis menu button: <pre>
 
<span class='st_sharethis' st_title='<?php the_title(); ?>' st_url='<?php the_permalink(); ?>'></span>
 
<span class='st_sharethis' st_title='<?php the_title(); ?>' st_url='<?php the_permalink(); ?>'></span>
 
</pre>
 
</pre>
Line 18: Line 18:
 
<script charset="utf-8" type="text/javascript" src="https://ws.sharethis.com/button/buttons.js"></script>
 
<script charset="utf-8" type="text/javascript" src="https://ws.sharethis.com/button/buttons.js"></script>
 
</pre>
 
</pre>
 +
Hovering over the ShareThis button should now display the popup. Should there be discrepancies, please look at how GilmoreCarMuseum has it implemented and adjust this page accordingly.

Revision as of 15:18, 28 January 2016

While we should NOT be using this plugin, for the plugin has been broken for months by admittance of the plugin creator, should there be no way around it, this is how to implement it and how it is implemented on the following sites:

 
www.gilmorecarmuseum.org
www.saultstemarie.com 

Nothing you do on the admin side will be of consequence following this 'guide', but make sure the plugin is active. For the display: place our own social media icons with graphics that complement the existing ShareThis button - you CAN replace this with CSS: important!, e.g.:

#soc-top .stButton .sharethis, #soc-bottom .stButton .sharethis {
  background-image: url("../assets/share-icon.jpg") !important;
}
then for the ShareThis menu button:
<span class='st_sharethis' st_title='<?php the_title(); ?>' st_url='<?php the_permalink(); ?>'></span>

For the footer or wherever you're supposed to throw your Javascript (like source > js > custom > pageSetup.js if that is still the current convention):

<script charset="utf-8" type="text/javascript" src="https://ws.sharethis.com/button/buttons.js"></script>

Hovering over the ShareThis button should now display the popup. Should there be discrepancies, please look at how GilmoreCarMuseum has it implemented and adjust this page accordingly.