The rubber bands idea didn't work for me, and the shortening the cord just meant it travelled sideways which was just as aggravating....
I tried the idea that Crafty Geminin had and that wasn't successful either. The carpet was too plush and the foot pedal moved because it would depress the pile when the pedal was depressed. My current fix is the best one yet!