Question: Upon checking Task Manager (Windows 7), I have approximately 60 instances of `javaw.exe` running, ranging from approx. 1,000K - 450,000K.

I am currently working on a large project, developing some software using Eclipse Helios.

Can somebody explain why this is happening?

Answer: 
You can do something like,

```
<script type="text/javascript">
  var btn_submit_pressed = false;

  $(window).bind('beforeunload', function(){
      if ( btn_submit_pressed )
          return 'If you want to exit page, you may lost your writing';
  });

  $('#btn_submit').click(function(){ btn_submit_pressed=true; });

</script>

```
You could introduce a variable:

```
var isSaved = true;  // at the beginning there's nothing unsaved

```

Whenever the user updates something, set:

```
isSaved = false;

```

When the user clicks submit, set:

```
isSaved = true;

```

Then in `beforeunload`, just check:

```
if(!isSaved) {

```