updated controller, added newlanguage function