the curly bracket should be on this line .. same goes for all the foreach statements below