ASP.NET control with jquery in seperate .js file
<p>i have just wrote a jquery voting script which is working fine if i leave the code within the header of the page.  however im looking to move it to a seperate .js file and then just include this .js at the top of the page. for some reason when i do this i get an exception error occurs on the  control!!!  can anyone advise how to get round this?  my code is below</p>

<pre><code>&lt;script type="text/javascript"&gt;
        $(document).ready(function () {
        $(".voteup").live("click", function () {

        &lt;asp:LoginView runat="server"&gt;
            &lt;LoggedInTemplate&gt;

// if user is logged in, allow them to vote

&lt;/LoggedInTemplate&gt;
});
});
&lt;/script&gt;
</code></pre>

<p>Thanks in advance,
David</p>
