Change function val for text function