<div class="command_shell">$ </div>

<script type="text/javascript">
  if(!window.window.commandShellRefreshId) {
    window.window.commandShellRefreshId = setInterval(function() {
      var currentTime = new Date().getTime();

      $.ajax({
        url: 'shell/read?session_id=' + Evader.sessionId + '&random=' + currentTime,
        dataType: 'text',
        success: function(data) {
          if(data.length > 0) {
            $('.command_shell').append(data + '<br /><br />$ ');
            var lines = $('.command_shell').html().split('<br>');
            $('.command_shell').scrollTop(lines.length * 15);
          }
        }
      });
    }, 1000);
  }
</script>