Forum:Want to integrate stumbleupon badge

So my wiki is universaltriumvirate.wikia.com and I want to put a stumbleupon badge on the main page.

http://www.stumbleupon.com/dt/badges/create

It needs embedded via html I believe but I have no idea how to do it. Can anyone help? It'd be very appreciated! Stavrok (talk) 03:36, July 17, 2012 (UTC)


 * You'd have to add the embed code to a medaiwiki page (like MediaWiki:StumbleUpon) then use StumbleUpon where you'd like it to show up. Rappy 21:32, July 17, 2012 (UTC)


 * Can you explain exactly how I'd embed it into a mediawiki page? I tried doing that but I probably did something wrong and I can't figure it out. Stavrok (talk) 03:22, July 18, 2012 (UTC)


 * You take the code given on that page and place it into a MW page, like w:c:universaltriumvirate:MediaWiki:StumbleUpon. Then you use verbatim as explained above where you want it to show up. Rappy 03:46, July 18, 2012 (UTC)


 * Ok, I did that but I don't think it's working http://universaltriumvirate.wikia.com/wiki/MediaWiki:StumbleUpon. Stavrok (talk) 04:35, July 18, 2012 (UTC)

Taking a second look at this, you shouldn't even need the verbatim. The code generator tells you to add the script AND display it with . You should add the following script to w:c:universaltriumvirate:MediaWiki:Common.js: Then use the su:badge code above where you want to display it. You can also delete that MediaWiki page you set up. I thought the code you wanted to add displayed the box. Rappy 06:10, July 18, 2012 (UTC)


 * Thank you so much for your help so far, sorry I'm so inept at this... Okay does the http://universaltriumvirate.wikia.com/wiki/MediaWiki:Common.js page look right? When I try putting the "" on a page it doesn't do anything. Stavrok (talk) 06:17, July 18, 2012 (UTC)


 * OK. I just went and tested this... Wikia won't recognize any custom HTML tags like the  from above. Here's exactly what you need to do...


 * The code in Common.js should be fine. Add the  code to the w:c:universaltriumvirate:MediaWiki:StumbleUpon page instead. Then, use StumbleUpon where you want it to show up. You can see the result here.


 * Mate, thank you! That worked perfectly! One question though, is there any way to change the appearance to one of the other versions of the stumbleupon badges? See this page, http://www.stumbleupon.com/dt/badges/create/, they're all fine but if I had the choice I'd want the second one down. Or do I not have a choice? Stavrok (talk) 06:31, July 18, 2012 (UTC)


 * Change the '5' to '2' in w:c:universaltriumvirate:MediaWiki:StumbleUpon. Rappy 06:33, July 18, 2012 (UTC)


 * Ok! Great! Once again thank you, that's a major help! Stavrok (talk) 06:36, July 18, 2012 (UTC)

Facebook?
It's fine if you don't but I don't suppose you'd know how to do a similar thing with a facebook like button? I used this forum (http://community.wikia.com/wiki/Forum:Facebook_Like_Box) as a guide but it's showing up weird on the main page. Stavrok (talk) 07:16, July 18, 2012 (UTC)


 * Facebook should already be covered in the Share button on every page already. But, if you want it elsewhere, others have done so. Admin Tools Wiki has a 'social' footer at the bottom of each page. Rappy 07:11, July 18, 2012 (UTC)


 * I mean a like button. The forum I referenced up there talks about being able to add it in the same kind of way you helped me add the stumbleupon button. Stavrok (talk) 07:16, July 18, 2012 (UTC)


 * Basically the same thing. Go here and generate your code. Place it in Common.js and use the code it tells you where you'd want to use it. Rappy 07:23, July 18, 2012 (UTC)

On my http://universaltriumvirate.wikia.com/wiki/MediaWiki:Common.js page, something isn't turning out quite right, I pasted the code exactly and put the same link it told me on the home page (do I need to make a page like the MediaWiki:StumbleUpon one, and then use verbatim?) Adding it actually made the stumbleupon button stop working too. Stavrok (talk) 07:38, July 18, 2012 (UTC)

(function(d, s, id) { var js, fjs = d.getElementsByTagName(s)[0]; if (d.getElementById(id)) return; js = d.createElement(s); js.id = id; js.src = "//connect.facebook.net/en_US/all.js#xfbml=1"; fjs.parentNode.insertBefore(js, fjs); }(document, 'script', 'facebook-jssdk'));


 * Remove the red parts. Then, use the code it showed you in the #2 spot to display the button. Rappy 08:01, July 18, 2012 (UTC)


 * I did that but if you look on the main page http://universaltriumvirate.wikia.com/wiki/Universal_Triumvirate_Wiki, nothing shows up (it should show up right under the stumbleupon button). Stavrok (talk) 17:58, July 18, 2012 (UTC)


 * I am seeing both. It's a cache issue. Try to clear your cache a few times with Ctrl-F5 until it shows up or wait. Sometimes logging out then back in refreshes your session cache too. Rappy 18:06, July 18, 2012 (UTC)


 * Oh, yup, now it's working. Thank you so much mate, I'm sorry I'm such an idiot at these things, but you know what you're doing and you've been a great help! Thank you! Stavrok (talk) 19:02, July 18, 2012 (UTC)

Follow Up Question
I want to put a like box (like box) instead of a like button (like box could link to our page on facebook), I've tried doing the same thing but it's not working. Can anyone help me out? 03:33, July 28, 2012 (UTC)


 * You're going to have to restore w:c:universaltriumvirate:MediaWiki:Facebook and place the code from https://developers.facebook.com/docs/reference/plugins/like-box/ (part 2 of the HTML5 code when clicking "Get Code") into that page. Then, use &lt;verbatim>Facebook&lt;/verbatim> where you want it to show up. Rappy 17:06, July 28, 2012 (UTC)