Changed .attr to .prop for jQuery 2

.attr was been depreciated with jQuery 2 it is also ~15% faster to access is jsperf.com benchmarks