there are shampoos specifically for this. body glove makes one, or ask the lifeguards at a local pool what they use. there are also some available at beauty supply stores. in the future wet your hair prior to going in the pool or use a leave in conditioner like infusium. alternatively you could use a swimming cap.
Put lemon juice in your hair and leave it for a few hours then wash your hair. Spray your hair with water before going in the pool to keep it from turning green. Your hair absorbs the fresh water and not the chloreen water.