Ask a Mechanic Online and Get Answers to Your Car Questions
The most likely causes of the gauge being wrong are either the new sensor that you installed is defective, the wiring to the sensor was damaged during replacement, or the sensor is not the correct part. There are two types of sensors for the elantra, one operates a light that tells that the car is overheating, and the other operates a gauge that tells the temperature of the car. It sounds like your elantra is equipped with the second option. You will need to make sure the sensor you got is for the style with the gauge and not just a light.
If you are certain that the part is correct the next step is to test the signal from the temp sensor to see if it is defective. Do you have a multi-meter to test the sensor?
Do you need additional help with this vehicle or did you get it sorted out?