$(document).ready(function(){
    // Show the language used in the <pre>
	$('pre').each(function(){
        var title = $(this).attr("class");
        if(title != ''){
            if(title.match('sourceCode')){
                var title = title.split(' ')[1];
            };
            $(this).prepend('<span class="language">'+title+'</span>');
        };
    });
    // Append Footnote to footnote div's created by Markdown
    $('.footnotes').each(function(){
        $(this).before('<h2>Footnotes</h2>');
    });
});
