Jquery Is this the correct way?
<pre><code>&lt;script type="text/javascript"&gt;
        if (SOMECONDITION) {
            $("#scriptD").attr("src", "../../Scripts/A.js");
        } else {
            $("#scriptD").attr("src", "../../Scripts/B.js");
        }

&lt;/script&gt;

&lt;script id="scriptD" src="" type="text/javascript"&gt;&lt;/script&gt;
</code></pre>

<p>I am trying to insert a <code>.js</code> file dynamically ( on the condition basis). But this is not working . Can anybody tell me whats the problem here? </p>
