Add Login Form

Add login form, though without login process.
Alter order of JavaScript code for easier future development.