Condensing / Optimizing a small piece of jquery code that hides/shows text upon clicking a input
<p>I'm looking for a way to simplify and condense this code a bit. I remember doing it ages ago but can't remember how I did it :\</p>

<pre><code>$('#chat_message_input').click(function() {
    if($(this).val() == 'Type your message here.') {
        $(this).val('');
    }
});
$('#chat_message_input').blur(function() {
    if($(this).val() == '') {
        $(this).val('Type your message here.');
    }
});
</code></pre>

<p>Thanks :)</p>
