IBS has been linked to low levels of beneficial intestinal flora. Probiotic cultures, like kefir, and prebiotics like FOS and other fibers will help the condition. Other cultured foods like raw sauerkraut will also help get the flora numbers back up.
The green stool results from food passing through the digestive system too quick. The drug was slowing the food passage down, so when you go off it speeds back up. Once the flora are built back up then the intestines should be better regulated and the stool color should return to normal.