Skip to main content
Topic: Simple trick - add Font Awesome social icons to Elkarte beSocial theme (Read 2572 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Simple trick - add Font Awesome social icons to Elkarte beSocial theme

Well this is not my code, I steal it from the Lattice theme made by @Spuds but I think could be useful to other beginners like me.

In themes\default\index.template.php find
Code: [Select]
	// Footer is full-width. Wrapper inside automatically matches admin width setting.
echo '
<div id="footer_section"><a id="bot"></a>
<div class="wrapper">
<ul>
<li class="copyright">',
theme_copyright(), '
</li>',
!empty($context['newsfeed_urls']['rss']) ? '<li>
<a id="button_rss" href="' . $context['newsfeed_urls']['rss'] . '" class="rssfeeds new_win"><i class="largetext fa fa-rss"></i></a>
</li>' : '',
'</ul>';

and replace with:

Code: [Select]
	// Footer is full-width. Wrapper inside automatically matches admin width setting.
echo '
<div id="footer_section"><a id="bot"></a>
<div class="wrapper">
<ul>
<li class="copyright">',
theme_copyright(), '
</li>
<div id="sociallinks" class="floatright">
<li>
<a id="button_rss" target="_blank" title="Facebook" href="http://www.facebook.com/your_link"><i class="largetext fa fa-facebook"></i></a>
</li>
<li>
<a target="_blank" title="Twitter" href="http://twitter.com/your_link"><i class="largetext fa fa-twitter"></i></a>
</li>
<li>
<a target="_blank" title="Google+" href="https://plus.google.com/+your_link"><i class="largetext fa fa-google-plus"></i></a>
</li>', !empty($context['newsfeed_urls']['rss']) ? '<li>
<a id="button_rss" href="' . $context['newsfeed_urls']['rss'] . '"><i class="largetext fa fa-rss"></i></a>
</li>' : '', '
</div>
</ul>';

Remember to thange "your_link" with your link ;)

If you don't have a custom_besocial.css file create it into themes/default/css/_besocial/custom_besocial.css and add inside:
Code: [Select]
#sociallinks ul {
    float: left;
    margin: 0;
    padding: 0;
}
#sociallinks li {
    float: left;
font-size: large;
    list-style: none outside none;
    padding: 0 5px;
}

I did not test it but I think the same code will apply to Elkarte Light template

The result:
Last Edit: January 10, 2015, 04:51:52 pm by radu81
sorry for my bad english

Re: Simple trick - add Font Awesome social icons to Elkarte beSocial theme

Reply #1

Nice :)

In your code you have small typo - <ul> tag opened twice, remove second one.

Re: Simple trick - add Font Awesome social icons to Elkarte beSocial theme

Reply #2

  :-[  thaks Phantom
sorry for my bad english