diff --git a/computer-science-blog/scripts/scripts.js b/computer-science-blog/scripts/scripts.js index 12c1d99..7602abf 100644 --- a/computer-science-blog/scripts/scripts.js +++ b/computer-science-blog/scripts/scripts.js @@ -1,31 +1,6 @@ // set page title window.page_title = "Computer Science Blog | Matthew Grove"; -function nextPage() { - // if there are more slides to come, display the next one - if (window.current_blog_page < window.pages.length) { - displayPage(window.pages[window.current_blog_page + 1]); - } else { - // if end of presentation has been reached, display the first slide - displayPage(window.pages[0]); - } -} - -function previousPage() { - // if there are more slides before the current one, display the previous slide - if (window.current_blog_page >= 1) { - displayPage(window.pages[window.current_blog_page - 1]); - } else { - // if end of presentation has been reached, display the first slide - displayPage(window.pages[window.pages.length - 1]); - } -} - -function displayPage(page) { - // document.getElementById("iframe").src = "pages/" + page + ".html"; - $("#presentation").load(page); -} - window.onload = function() { // set the current date var date = new Date(); @@ -39,6 +14,9 @@ window.onload = function() { // display date $("#current_date").html(current_date); + // display first blog page + $("#blog-insert").load("pages/blog.html"); + // define variables for HTTP presentation pages http_pages = ["hyperlinks", "http", "https", "cookies"]; // displays HTTP presentation pages @@ -46,10 +24,10 @@ window.onload = function() { $.get("pages/" + item + ".html", function(content) { if (index == 0) { $("#http_presentation .carousel-inner").append('