Forum Index >  General >  General Support New Topic Post Reply
 More Questions
   |  Printable Version
By: Veloxi (offline)  Feb 03 2009 11:13 am (Read 1759 times)  
Veloxi

Hey guys, got a couple of questions for ya:

1. I wanna add code from AddThis (a social bookmarking thingy) to the site so that it shows up on each of our entries, kind of like where the digg, print and email buttons are now. Here's the code:

PHP Formatted Code
<!-- AddThis Button BEGIN -->
<script type="text/javascript">var addthis_pub="veloxi";</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 -->



Where would I add this in the template to make it visible on each entry?

2. Is there a way to make a certain block of text invisible unless its highlighted? We plan on doing this to post spoilers so only those who wish to see them can highlight them. The simplest thing I can think of is to make the text a certain color, but I'm not sure if that'll always work.

Thanks!

Forum Active Member
Active Member

Group Comfort
Level:
: +1

Registered: 11/20/08
Posts: 137
Location: Los Angeles, CA

Profile Email Website  
  Quote
By: Veloxi (offline)  Feb 03 2009 12:59 pm  
Veloxi

3. Forgot to add this earlier. As part of the "Addthis" thing mentioned above, I also want to add the following code to the stories them in the "Story Options" section below "Printable Story Format"

PHP Formatted Code
<!-- AddThis Button BEGIN --><script type="text/javascript">var addthis_pub="veloxi"; var addthis_options = 'facebook, myspace, twitter, delicious, favorites, digg, reddit, friendfeed, google, live, stumbleupon,  more';</script><a href="http://www.addthis.com/bookmark.php"
        style="text-decoration:none;"
        onmouseover="return addthis_open(this, '', '[URL]', '[TITLE]');"
        onmouseout="addthis_close();"
        onclick="return addthis_sendto();">Bookmark or Share</a><script type="text/javascript" src="http://s7.addthis.com/js/200/addthis_widget.js"></script><!-- AddThis Button END -->



Where would I add this into the code of the site's template?

Thanks!

Forum Active Member
Active Member

Group Comfort
Level:
: +1

Registered: 11/20/08
Posts: 137
Location: Los Angeles, CA

Profile Email Website  
  Quote
By: lgarner (offline)  Feb 03 2009 13:47 pm  
lgarner

Check in storytext.thtml and featuredstorytext.thtml. You can add your AddThis code right after the

PHP Formatted Code
<!-- end Digg.com icon code -->



I'd then also disable Digg in the site config since it seems to be part of AddThis.

Forum Admin
Admin

Group Comfort
Level:
: +52

Registered: 06/10/08
Posts: 1912

Profile Email Website  
  Quote
By: Veloxi (offline)  Feb 03 2009 14:02 pm  
Veloxi

Yay, that worked, sadly, the Addthis code didn't, as it only linked to the base site, not the article itself. Ah well, I can add it elsewhere. Thanks!

Forum Active Member
Active Member

Group Comfort
Level:
: +1

Registered: 11/20/08
Posts: 137
Location: Los Angeles, CA

Profile Email Website  
  Quote
By: lgarner (offline)  Feb 03 2009 18:03 pm  
lgarner

You could try substituting {article_url} in place of [URL] in the AddThis link. In storytext.thtml you should see

digg_url = '{article_url}'; //permalink to article

which looks like it would work for AddThis also. I don't know about the TITLE value.

Forum Admin
Admin

Group Comfort
Level:
: +52

Registered: 06/10/08
Posts: 1912

Profile Email Website  
  Quote
By: Veloxi (offline)  Feb 03 2009 18:17 pm  
Veloxi

Quote by: lgarner

You could try substituting {article_url} in place of [URL] in the AddThis link. In storytext.thtml you should see

digg_url = '{article_url}'; //permalink to article

which looks like it would work for AddThis also. I don't know about the TITLE value.


AWESOME! That did the trick! Thank you!

However, question, this isn't showing up in the featured article. How can I add it there?

Forum Active Member
Active Member

Group Comfort
Level:
: +1

Registered: 11/20/08
Posts: 137
Location: Los Angeles, CA

Profile Email Website  
  Quote
By: lgarner (offline)  Feb 03 2009 21:20 pm  
lgarner

Do the same thing in featuredstorytext.thtml.

Forum Admin
Admin

Group Comfort
Level:
: +52

Registered: 06/10/08
Posts: 1912

Profile Email Website  
  Quote
By: Veloxi (offline)  Feb 03 2009 21:31 pm  
Veloxi

That did the trick. Thank you!

Forum Active Member
Active Member

Group Comfort
Level:
: +1

Registered: 11/20/08
Posts: 137
Location: Los Angeles, CA

Profile Email Website  
  Quote
By: Veloxi (offline)  Feb 13 2009 15:59 pm  
Veloxi

Hey guys, anyone have any idea on this?

2. Is there a way to make a certain block of text invisible unless its highlighted? We plan on doing this to post spoilers so only those who wish to see them can highlight them. The simplest thing I can think of is to make the text a certain color, but I'm not sure if that'll always work.



Thanks!

Forum Active Member
Active Member

Group Comfort
Level:
: +1

Registered: 11/20/08
Posts: 137
Location: Los Angeles, CA

Profile Email Website  
  Quote
By: Geiss (offline)  Feb 13 2009 16:15 pm  
Geiss

A quick Googling for "create spoiler text" reveals quite a few tips, of which http://www.yog-sothoth.com/modules.php? ... amp;t=4817 has some good ideas for use in a forum, and http://tips.blogdoctor.me/2007/11/creat ... posts.html has a nifty javascript solution.

Remember, Google is your friend! Big Grin

Thx!

Eric


Forum Active Member
Active Member

Group Comfort
Level:
: +58

Registered: 02/15/07
Posts: 2097
Location: Boise, Idaho

Profile Email Website  
  Quote
By: Veloxi (offline)  Feb 13 2009 17:50 pm  
Veloxi

Heh, I figured the simplest way was just to make it white like that one example, didn't know if there was a special way to "glFusion it." Wink Thanks!

Forum Active Member
Active Member

Group Comfort
Level:
: +1

Registered: 11/20/08
Posts: 137
Location: Los Angeles, CA

Profile Email Website  
  Quote
New Topic Post Reply


 All times are CDT. The time is now 10:26 am.
Normal Topic Normal Topic
Locked Topic Locked Topic
Sticky Topic Sticky Topic
New Post New Post
Sticky Topic w/ New Post Sticky Topic w/ New Post
Locked Topic w/ New Post Locked Topic w/ New Post
View Anonymous Posts 
Able to Post 
HTML Allowed 
Censored Content