What's wrong with this?
$('tbody').on('click', '.expand', function () {
var $button = $(this);
var chart = $button.closest('tr').attr('chart');
$('tr[chart="' + chart + '"]').slideDown('fast', function () {
$button.text('-').removeClass('expand').addClass('contract');
});
});
Chrome tells me Uncaught TypeError: Object #<Object> has no method 'on'
Update:
Ok so I decided to upgrade. I upgraded to 1.10 because I may well have IE7/8 users, but every page gives this error now: Uncaught TypeError: Cannot call method 'replace' of undefined
Will try an earlier version.
Resolution:
Version 1.7.2 works great :)