changed controls from else if to if's