otpimize code, include selectboxes as class attributes