Uncaught ReferenceError JavaScript
<p>Ok, so I have a template which I am using to print a couple of users to a table. </p>

<pre><code>function PrintUsers(item) {
    $.template('userList', '&lt;tr onClick="OnUserPressed(${Identifier})"&gt;\
    &lt;td&gt;${Firstname}&lt;/td&gt;\
    &lt;td&gt;${Lastname}&lt;/td&gt;\
    &lt;/tr&gt;');

    $.tmpl('userList', item).appendTo("#UserTableContainer");
}
</code></pre>

<p>When I press a user I want his/hers unique identifier to be passed to a function called OnUserPressed which I am declaring in the template. The code below is just a test to see if it actually passes the data to the function.</p>

<pre><code>    function OnUserPressed(Identifier) {
        alert(Identifier);
    }
</code></pre>

<p>My problems are these: When I press the first value in the table I get "Uncaught SyntaxError: Unexpected token ILLEGAL". When I press any other value in the table I get "Uncaught ReferenceError: xxx is not defined" where xxx is their unique identifier. So it actually retrieves the ID but I still get an error. </p>

<p>Any thoughts?</p>
