view and controller coding