slicing out unneeded text from string