in jQuery, attr instead of writeAttribute. Alse, I had to add # before Ids