I had a problem with my shifter a few years ago that started just like that. The wires going to the shifter/solenoid had become brittle and broken at the plug. Take the center console out (just pops out, IIRC) and check the wires where they're connected to the plug on either side.