Here are the problems that I'm facing with a small jQuery script :
Check out My jsFiddle to see the problems in action.
****** MIND READING MODE ON ******
I think this is what you need:
http://jsfiddle.net/nicolapeluchetti/pgDcq/4/
Tell me if it's ok
UPDATE
****** MIND READING MODE OFF******
Mission accomplished