Hello,
I've just spent a long time trying to figure out why my Javascript for() loop won't work in a Drupal block, I feel like I've checked out the syntax - any idea why this isn't working?!
$(document).ready(function() {
var i=0;
while (i<=5)
{
alert(i);
i++;
}
});
That doesn't do anything - and also if I put something like this in- does not work either:
for (var i=0; i<31; i++){
alert(i);
}
Thanks!