Added ability to set the view script and layout in the controller