What is the difference between those two statements?
A:
$(document.getElementById('timer-' + endTimes[i].nid)).removeClass('hidden-timer').text('');
B:
$('#timer-' + endTimes[i].nid).removeClass('hidden-timer').text('');
[EDIT]
Thanks for all responses.
endTimes[i].nid is numeric, ex 340.
The most important difference for me was that line A is causing a WSOD, but line B works fine.
Both do the same, except that the selector can mess up with special characters: http://jsfiddle.net/pimvdb/Mwrpb/.