My iPhone charger went through the washing machine, will it work still?

Or do I need to get another one

If it is really the charger (the part you plug into the wall or cigarette lighter jack), don't risk it. Replace it. If it is merely the cable, it may be OK after it is completely dry.