changed from .attr to .prop