Skin and templates fixes
JavaScript refactor and structuration