bugfixing with attribute data and jquery