Ver original$("#campo").click(function (){if( $("#input1").val() == "") {var _span = $("<span id='error'>Error</span>").hide();$("#input1").focus().after(_span);_span.fadeIn(500);}});