git.haldean.org docstore / 2aaf429
Use Github Raw to display Markdown Will Brown 9 years ago
1 changed file(s) with 3 addition(s) and 2 deletion(s). Raw diff Collapse all Expand all
1010 var url = 'text/' + page + '.md'
1111
1212 document.title = page;
13 document.getElementById("viewsource").setAttribute("href", url)
13 document.getElementById('viewsource').setAttribute('href',
14 'https://raw.github.com/haldean/docstore/master/' + url)
1415
1516 $.ajax({
1617 url: url,
2021 window.location = homepage
2122 }
2223
23 document.getElementById("content").innerHTML = markdown.toHTML(resp)
24 document.getElementById('content').innerHTML = markdown.toHTML(resp)
2425 $('pre').each(function(el, index) {
2526 hljs.highlightBlock(el, ' ')
2627 })