fixed file loading on page load