is there a way to have one drop down box control another box?

example:

drop down #1 says shirt size (s m l)

drop down #2 - if s selected only blue color appears, if m and large selected red and blue colors become the options.