Simple Machines Community Forum

SMF Support => SMF 2.0.x Support => Aiheen aloitti: Verso - maaliskuu 26, 2009, 07:28:43 AP

Otsikko: AddThis
Kirjoitti: Verso - maaliskuu 26, 2009, 07:28:43 AP
I have found a great tool called AddThis (lets you add forum posts to social network sites)

I have been given code:-

Lainaa<!-- AddThis Button BEGIN -->
<script type="text/javascript">var addthis_pub="verso2009";</script>
<a href="http://www.addthis.com/bookmark.php?v=20" onmouseover="return addthis_open(this, '', '[URL]', '[TITLE]')" onmouseout="addthis_close()" onclick="return addthis_sendto()"><img src="http://s7.addthis.com/static/btn/lg-share-en.gif" width="125" height="16" alt="Bookmark and Share" style="border:0"/></a><script type="text/javascript" src="http://s7.addthis.com/js/200/addthis_widget.js"></script>
<!-- AddThis Button END -->

I am being told to put this in the Display.template.php file


I have tried doing this but it screws up my forum.


Is anyone else using this feature and if so please can you assist?

Otsikko: Re: AddThis
Kirjoitti: Marcus Forsberg - maaliskuu 28, 2009, 04:18:03 AP
Hello.

If you attach Display.template.php in your next post, I'll fix this for you.
Otsikko: Re: AddThis
Kirjoitti: Verso - maaliskuu 28, 2009, 04:31:15 AP
http://www.suffolksportsforum.co.uk/index.php/topic,10048.msg14355.html


Thank you.........

If you click the link you will see that last night I managed to get the SHARE button into the very top left hand corner........


Could you fix this so it appears next to this:- Topic: Holland v Scotland  (Read 76 times)
Otsikko: Re: AddThis
Kirjoitti: Marcus Forsberg - maaliskuu 28, 2009, 04:45:00 AP
Try this:
Otsikko: Re: AddThis
Kirjoitti: Verso - maaliskuu 28, 2009, 05:00:35 AP
I get this:-

Template Parse Error!
There was a problem loading the /Themes/default/Display.template.php template or language file. Please check the syntax and try again - remember, single quotes (') often have to be escaped with a slash (\). To see more specific error information from PHP, try accessing the file directly.

You may want to try to refresh this page or use the default theme.
syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting ',' or ';'
Otsikko: Re: AddThis
Kirjoitti: Marcus Forsberg - maaliskuu 28, 2009, 05:02:34 AP
Sorry, my bad. This should work:
Otsikko: Re: AddThis
Kirjoitti: Verso - maaliskuu 28, 2009, 05:10:58 AP
Legendary

Many thanks
Otsikko: Re: AddThis
Kirjoitti: Marcus Forsberg - maaliskuu 28, 2009, 05:12:12 AP
You're welcome.
Topic marked as solved.
Otsikko: Re: AddThis
Kirjoitti: Verso - kesäkuu 01, 2009, 05:16:21 IP
Hello,

I have reinstalled my forum software and I forgot to save the display.template file first so I have lost my ADDTHIS code...........


Please could someone amend my display.template to make the ADDTHIS button appear next to (Read 15 times)



Otsikko: Re: AddThis
Kirjoitti: Verso - kesäkuu 05, 2009, 04:40:28 AP
Can anyone help?
Otsikko: Re: AddThis
Kirjoitti: Verso - kesäkuu 05, 2009, 07:56:07 AP
Lainaus käyttäjältä: Arantor - kesäkuu 05, 2009, 07:28:20 AP
Is it the one as attached above?


Yes it is
Otsikko: Re: AddThis
Kirjoitti: Verso - kesäkuu 05, 2009, 08:23:20 AP
I have done but this places the button in the top right hand of forum and makes the text larger..........


http://www.suffolksportsforum.co.uk/index.php/topic,11329.0.html
Otsikko: Re: AddThis
Kirjoitti: Verso - kesäkuu 05, 2009, 08:52:48 AP
So basically I have a slight problem. I added the code to my display.template.php and the addthis button appears in the top right of my forum. I would liked it on the section that shows:-  (Read 15 times) as in the post above:- http://www.simplemachines.org/community/index.php?topic=301295.msg2089109#msg2089109


Not only is the button in a place I don't want it to be but it has forced all fonts to increase to large (see an example by clicking my link in previous post)


Is there anyone out there that can tweak the attached file to fix this for me????
Otsikko: Re: AddThis
Kirjoitti: Bulakbol - kesäkuu 06, 2009, 08:29:28 IP
Check this mod.
http://custom.simplemachines.org/mods/index.php?mod=1817
Otsikko: Re: AddThis
Kirjoitti: XcLusive0409 - syyskuu 05, 2009, 01:22:29 AP
Hi, i having the same prob adding the addthis button to my forum i'm using SMF 2.0 RCI 1.2...i tried soo many times had to install the forum again

i attached my file if its possible to help me to edit it that will be really helpful thxx
Otsikko: Re: AddThis
Kirjoitti: XcLusive0409 - syyskuu 05, 2009, 10:34:07 IP
can sum1 help me really...??