Plant Identification: Need help identifying this plant

Was given to me as gift and have had for 2 years but do not know what the name of plant is and how to correctly care for it. Scanned a picture of the leaf. Also, when you remove leaf from plant it produces a white milky liquid.

Plant has not been doing well and trying to treat it correctly. Recently transplanted to different pot and fresh soil.