Correct way to setup a function call from event?
<p>Is this the way to setup my event to call a function?</p>

<p>I have this in a document.ready</p>

<pre><code>$(document).on('change', "[data-viewlink]",
    function ()
    {
        UpdateViewLink($(this).attr("id"));
    }
);
</code></pre>

<p>The <code>UpdateViewLink()</code> function is surrounded by a <code>function()</code>. It is a single call and am wondering if <code>function(){}</code> is required. Is this the correct way to set this up?</p>

<p>I also call <code>UpdateViewLink()</code> from normal functions.</p>
