$(document).on('click', '.page-link', function(event){
event.preventDefault(); var link = $.attr(this, 'href') var noSlashLink = link.replace(/\//g, "") $('html, body').animate({ scrollTop: $( noSlashLink ).offset().top - 75 }, 500);
});
function resize() {
var heights = window.innerHeight; var homeDiv = document.getElementById("home"); homeDiv.style.height = heights + "px"; homeDiv.style.minHeight = heights + "px"; // if(homeDiv) { // homeDiv.style.height = heights + "px"; // homeDiv.style.minHeight = heights + "px"; // }
}
window.onresize = function() {
resize();
};
resize();
$(function() {
var counterAmount = parseInt($('#views-counter span').text()); var scene = document.getElementById('scene'); var parallax = new Parallax(scene); setInterval(function() { var randomnumber = Math.floor(Math.random() * (500 - 100)) + 100; counterAmount = counterAmount + randomnumber; $('#views-counter span').text(counterAmount + ' views'); }, 1000);
})