getting ready to set up the view function