(Not sure if this is the right area to post in)

I have K&K Pure mini pickups (contact pickups), so they pick up and amplify pretty much anything that vibrates within my guitar. So my problem is that when I play the body percussively, the cords from the pickups etc rattle inside my guitar - which is then amplified, which doesn't sound good

I've tried a couple of methods to restrain the cords, however, I haven't been successful so far - so my (probably stupid :P ) question is this: What is the best way to restrain the cords and keep them from rattling?

I hope that makes sense.