brake problems

ok my abs light is on on my car and every once and awhile my foot will go to the floor and it will not brake very well and then you pump it and it will work i dont know what to do its buggin me
thanks
justin