diff options
author | Thedro Neely <thedroneely@gmail.com> | 2018-12-16 11:39:12 -0500 |
---|---|---|
committer | Thedro Neely <thedroneely@gmail.com> | 2018-12-16 11:39:12 -0500 |
commit | 4b8ac0cc26c4d8b85a1e1805d0a3164b10d4cb9a (patch) | |
tree | 78ee7bd7e5d92ec5fb9e88cbfa0e7972d27302d5 | |
parent | fc00dddeb72ee8ff506512ddb82d249b49c0dde0 (diff) | |
download | thedroneely.com-4b8ac0cc26c4d8b85a1e1805d0a3164b10d4cb9a.tar.gz thedroneely.com-4b8ac0cc26c4d8b85a1e1805d0a3164b10d4cb9a.tar.bz2 thedroneely.com-4b8ac0cc26c4d8b85a1e1805d0a3164b10d4cb9a.zip |
app/views/partials/footer: Remove inline JavaScript to single file
Keep closing body and html tag outside of footer
-rw-r--r-- | app/views/contact.view.php | 5 | ||||
-rw-r--r-- | app/views/index.view.php | 71 | ||||
-rw-r--r-- | app/views/mail-error.view.php | 3 | ||||
-rw-r--r-- | app/views/mail-sent.view.php | 9 | ||||
-rw-r--r-- | app/views/partials/footer.php | 85 |
5 files changed, 54 insertions, 119 deletions
diff --git a/app/views/contact.view.php b/app/views/contact.view.php index bfc0da5..542be6b 100644 --- a/app/views/contact.view.php +++ b/app/views/contact.view.php @@ -2,7 +2,7 @@ <body> - <section class="section is-fullheight" itemscope itemtype="http://schema.org/WebPage"> + <section class="section" itemscope itemtype="http://schema.org/WebPage"> <div class="hero-head"> @@ -84,3 +84,6 @@ </div> <?php require __DIR__ . '/partials/footer.php'; ?> + + </body> +</html> diff --git a/app/views/index.view.php b/app/views/index.view.php index e1232fd..ba1a7b1 100644 --- a/app/views/index.view.php +++ b/app/views/index.view.php @@ -46,52 +46,48 @@ <div class="columns"> - <div class="column"> - <h3 class="has-text-dark is-marginless is-size-5"> - Recent Posts - </h3> + <div class="column has-text-centered"> + <div class="front__textbox has-text-left-desktop is-inline-block"> - <br> + <h3 class="has-text-dark is-marginless is-size-5"> + Recent Posts + </h3> - <a class="underline__hover line__height" href="/post/bitcoin-hacked-email-scam/">Bitcoin Hacked Email Scam</a> + <?php + $recent_posts = file($_SERVER['DOCUMENT_ROOT'] . '/post/index.html'); + foreach (range(count($recent_posts) - 32, count($recent_posts) - 24) as $line) { + echo $recent_posts[$line]; + } + ?> - <br> + <br> + <br> - <a class="underline__hover line__height" href="/post/my-sublime-text-setup/">My Sublime Text Setup</a> - - <br> - - <a class="underline__hover line__height" href="/post/mixing-php-into-hugo/">Mixing PHP into Hugo</a> - - <br> - <br> - - <a class="front__frame" href="post/">More posts <span class="icon">➤</span></a> + <a class="front__frame" href="post/">More posts <span class="icon">➤</span></a> + </div> </div> - <div class="column"> - <h3 class="has-text-dark is-marginless is-size-5"> - Recent Projects - </h3> - - <br> - - <a class="underline__hover line__height" href="/project/bulma-resume">Bulma Resume</a> + <div class="column has-text-centered"> + <div class="front__textbox has-text-left-desktop is-inline-block"> - <br> + <h3 class="has-text-dark is-marginless is-size-5"> + Recent Projects + </h3> - <a class="underline__hover line__height" href="/project/personal-portfolio/">Personal Portfolio</a> + <?php + $recent_projects = file($_SERVER['DOCUMENT_ROOT'] . '/post/index.html'); + foreach (range(count($recent_projects) - 15, count($recent_projects) - 7) as $line) { + echo $recent_projects[$line]; + } + ?> - <br> + <br> + <br> - <a class="underline__hover line__height" href="/project/voiceover-website/">Voiceover Website</a> - - <br> - <br> - - <a class="front__frame" href="project/">More projects <span class="icon">➤</span></a> + <a class="front__frame" href="project/">More projects <span class="icon">➤</span></a> + </div> </div> </div> @@ -99,7 +95,12 @@ </div> </div> </div> -</section> + + </section> + <section> <?php require __DIR__ . '/partials/footer.php'; ?> + + </body> +</html> diff --git a/app/views/mail-error.view.php b/app/views/mail-error.view.php index 6ebc54e..4cd9808 100644 --- a/app/views/mail-error.view.php +++ b/app/views/mail-error.view.php @@ -27,3 +27,6 @@ </div> <?php require __DIR__ . '/partials/footer.php'; ?> + + </body> +</html> diff --git a/app/views/mail-sent.view.php b/app/views/mail-sent.view.php index 3ba0794..27384ae 100644 --- a/app/views/mail-sent.view.php +++ b/app/views/mail-sent.view.php @@ -3,16 +3,16 @@ <body> <section class="section hero is-fullheight" itemscope itemtype="http://schema.org/HomePage"> - <div class="hero-head"> + <div class="hero-head"> <?php require __DIR__ . '/partials/navigator.php'; ?> - </div> + <div class="hero-body"> <div class="container"> <div class="columns"> <div class="column is-8 is-offset-2 has-text-centered"> - <article style="text-align: center;"> + <article class="has-text-centered"> <h3>Thank you for your message.</h3> <a href="/"><b>Return to the Home Page</b></a> </article> @@ -22,3 +22,6 @@ </div> <?php require __DIR__ . '/partials/footer.php'; ?> + + </body> +</html> diff --git a/app/views/partials/footer.php b/app/views/partials/footer.php index 28024ee..ab07c8b 100644 --- a/app/views/partials/footer.php +++ b/app/views/partials/footer.php @@ -30,11 +30,12 @@ Built with <a href="https://secure.php.net/">PHP</a> | <a href="https://gohugo.io/">Hugo</a> | <a href="https://posativ.org/isso/">Isso</a> — - See development profile at <a href="https://github.com/tdro">Github</a> | + See my <a href="https://github.com/tdro">Github</a> | <a href="https://gitlab.com/tdro">Gitlab</a> — Subscribe to <a href="/rss.xml">RSS Feed</a> — Chat at <a href="https://keybase.io/tdro">Keybase</a> — - See my <a href="/resume">Resume</a> + Now on <a href="https://dev.to/tdro">DEV</a> — + View my <a href="/resume">Resume</a> </p> <br> @@ -55,86 +56,10 @@ </section> -<script type="application/ld+json"> -{ - "@context": "http://schema.org", - "@type": "WebSite", - "mainEntityOfPage": { - "@type": "WebPage", - "@id": "/" - }, - "name": "Thedro Neely: Portfolio", - "description": "Thedro's Personal Website", - "author": { - "@type": "Person", - "name": "Thedro Neely" - }, - "publisher": { - "name": "Thedro Neely", - "type": "Person" - - } -} -</script> - -<script> -document.addEventListener('DOMContentLoaded', function () { - var $navbarBurgers = Array.prototype.slice.call(document.querySelectorAll('.navbar-burger'), 0); - if ($navbarBurgers.length > 0) { - $navbarBurgers.forEach(function ($el) { - $el.addEventListener('click', function () { - var target = $el.dataset.target; - var $target = document.getElementById(target); - $el.classList.toggle('is-active'); - $target.classList.toggle('is-active'); - }); - }); - } -}); -</script> - -<script> -var activeBurger = document.getElementById('navBurger'); -var activeMenu = document.getElementById('navMenu'); -document.addEventListener('click', function(event) { - var burgerClick= activeBurger.contains(event.target); - if (!burgerClick && activeBurger.classList.contains('is-active')) { - activeBurger.className = "navbar-burger burger has-text-dark"; - activeMenu.className = "navbar__mobile navbar-menu"; - } -}); -</script> - -<script> -var pastPosition = window.pageYOffset; -var navbarHeight = document.getElementById("navbar").offsetHeight; -window.onscroll = function() { - var currentPosition = window.pageYOffset; - if (pastPosition > currentPosition) { - document.getElementById("navbar").style.top = "0"; - } else if (currentPosition > navbarHeight) { - document.getElementById("navbar").style.top = "-4.2em"; - } - if (activeBurger.classList.contains('is-active')) { - activeBurger.className = "navbar-burger burger has-text-dark"; - activeMenu.className = "navbar__mobile navbar-menu"; - } - pastPosition = currentPosition; - }; -</script> +<script src="/dist/app.js"></script> <?php if (trim($_SERVER['REQUEST_URI'], '/') == 'contact') { ?> -<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script> - -<script> - new Vue({ - el: '#contact-vue', - data: { name: '', email: '', message: '' } - }); -</script> +<script src="/js/VueDevelopment.js"></script> <?php } ?> - - </body> -</html> |