[jQuery] Why doesn't this work (a short one)

[jQuery] Why doesn't this work (a short one)

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
</head>
<body bgcolor="#ffffff" text="#000000">
<font face="Arial">The following code works perfectly fine:
1. Checks if a certain textarea exists.
2. Adds an input box straight after it.
3. Counts the number of characters in the textarea either (a) when it
becomes available or (b) on the keyup event.
       $("textarea#MessageBody")
        .after("<input id=\"CharCounter\"/>")
        .ready(function(){CharCounter($('textarea#MessageBody'));})
        .keyup(function(){CharCounter(this);});
But when i replace the 3rd line with:
</font><font face="Arial">        .ready(function(){CharCounter(this);})
It ceases to work.
How come?
Thanks to anyone helping me understand this.
</font>
</body>
</html>