I'm trying to figure out how to pass variables to jQuery functions, but I'm at a loss why this (greatly simplified) example doesn't work as intended. The idea is that an alert will be shown when the checkbox is clicked.

No problem here:

```
<input type="checkbox" class="check"/>

<script>

  do_alert = function() {
    alert("Welcome");
  }

  $('.check').change(do_alert);

</script>

```

However, when passing the alert text to the function, the alert is shown as soon as the page loads, with the correct message text:

```
<input type="checkbox" class="check"/>

<script>

  do_alert = function(message) {
    alert(message);
  }

  $('.check').change(do_alert("Welcome"));

</script>

```

As does this:

```
<input type="checkbox" class="check"/>

<script>

  function do_alert(message) {
    alert(message);
  }

  $('.check').change(do_alert("Welcome"));

</script>

```

In both cases, the function isn't executed when checking the box, but it is on loading the page. What am I missing here?