adding in functions to split input text