login and logout updated but will put cookies functionality later..