Hi there,
I’d like to add these floating social media buttons on my site according to this example:
https://www.w3schools.com/howto/howto_css_sticky_social_bar.asp
I’ve already implemented the CSS but don’t really know how to include the html code in the body to make the buttons appear right.
I tried to implement this code into the child theme’s functions.php but I’m getting an error. The font awesome library was excluded since xtheme is already loading those.
add_action( 'wp_head', 'my_custom_head_output', 99999 );
function my_custom_footer_output() {
?>
<!-- The social media icon bar -->
<div class="icon-bar">
<a href="#" class="facebook"><i class="fa fa-facebook"></i></a>
<a href="#" class="twitter"><i class="fa fa-twitter"></i></a>
<a href="#" class="google"><i class="fa fa-google"></i></a>
<a href="#" class="linkedin"><i class="fa fa-linkedin"></i></a>
<a href="#" class="youtube"><i class="fa fa-youtube"></i></a>
</div>
<?php
}
Best regards