<p>I'm trying to load a page that is basically an edit form inside a
dialog (ui.dialog).  I can load this page fine from an external (I'm
using asp.net) page.</p>

<p>The problem is that inside of my "popup" form, I need to <code>$(function()
{my function here});</code> syntax to do some stuff when the page loads,
along with registering some <code>.fn</code> extensions for some dynamic dropdowns
using ajax calls.</p>

<p>I have created my <code>&lt;script type="text/javascript" src="jquery.js"&gt;</code> but
I don't think these are being included, and also my <code>$(function)</code> is not
being called.</p>

<p>Is this possible to do or do I need to find another way of
accomplishing what I need to do? </p>

[{'answer_id': 64515, 'author': 'Alexey Lebedev', 'author_id': 8338, 'author_profile': 'https://Stackoverflow.com/users/8338', 'pm_score': 3, 'selected': True, 'text': '<p>If you really need to load that form via AJAX you could to do all the Javascript stuff in  $.ajax callback itself.\nSo, you load the popup form like this:</p>\n\n<pre><code>$.ajax({\n   //...\n   success: function(text) {\n       // insert text into container\n       // the code from $(function() {});\n   }\n});\n</code></pre>\n'}, {'answer_id': 164960, 'author': 'Ben Crouse', 'author_id': 6705, 'author_profile': 'https://Stackoverflow.com/users/6705', 'pm_score': 0, 'selected': False, 'text': "<p>The script isn't getting run because the document's ready event has already been fired. Remove your code from within the </p>\n\n<pre><code>$()\n</code></pre>\n"}, {'answer_id': 184651, 'author': 'Bopp', 'author_id': 21285, 'author_profile': 'https://Stackoverflow.com/users/21285', 'pm_score': 0, 'selected': False, 'text': '<p>Use the livequery plugin. </p>\n\n<p>It allows you to bind events to elements that might be loaded later: <a href="http://brandonaaron.net/docs/livequery/" rel="nofollow noreferrer">http://brandonaaron.net/docs/livequery/</a></p>\n'}]
['https://Stackoverflow.com/questions/64351', 'https://Stackoverflow.com', 'https://Stackoverflow.com/users/8534/']