Starting refactoring scan.html page.