Adding Social Sharing buttons to OSSN

Allon Prooit Posted in Beginning Developers 3 months ago

Hello,
Needing to add this script somewhere in the site to make it work. The share buttons come from a site that says you should paste it into the head of all html files. I can't figure out which files I should put it into. Any suggestions? This share function was made by RhythmOne at po.st

<script type="text/javascript">
// DO NOT IMPLEMENT //
// this code through the following //
// //
// Floodlight Pixel Manager //
// DCM Pixel Manager //
// Any system that places code in an iframe //
(function () {
var s = document.createElement('script');
s.type = 'text/javascript';
s.async = true;
s.src = ('https:' == document.location.protocol ? 'https://s' : 'http://i')
+ '.po.st/static/v4/post-widget.js#publisherKey=9dp5e8f935rlrmmvpagh';
var x = document.getElementsByTagName('script')[0];
x.parentNode.insertBefore(s, x);
})();
</script>

Replies
German ~Z~ Man Replied 3 months ago

> I can't figure out which files I should put it into

One more time: It's not recommended to alter any Ossn core file. See
https://www.opensource-socialnetwork.org/wiki/view/704/should-i-modify-core-files

Instead, use Homelancer's CUSTOM CSS/JS component
https://www.opensource-socialnetwork.org/component/view/2504/homelancer-custom-css-js

and enter/save your code there.