recode student servlets to single controller