added register template and logInTemplate