javascript updating view with name search