added functionality

getData is the function tim is writing
i messed everything up
the things finally work