.attr() now uses setAttribute() and getAttribute to make it work with data- attributes