Pass html textbox value from a jquery modal to asp code behind
<p>This code displays a Jquery dialog with an html textbox that is shown after the user clicks on an asp:button btnNewGroup</p>

<pre><code>&lt;script type="text/javascript" language="javascript"&gt;
function pageLoad(sender, args) {
    var $dialog = $('&lt;div&gt;&lt;fieldset&gt;&lt;label for="name"&gt;Name&lt;/label&gt;&lt;input type="text" name="Name" id="name" class="text ui-widget-content ui-corner-all" /&gt;&lt;/div&gt;')
        .dialog({
            modal: true,
            autoOpen: false,
            title: 'Enter New Group Name',
            buttons: {
                'New': function () {
                    $(this).dialog('close');
                },
                Cancel: function () {
                    $(this).dialog('close');
                }
            }
        });


        $("#&lt;%=btnNewGroup.ClientID %&gt;").click(function () {
            $dialog.dialog('open');
            return true;
        });
}
&lt;/script&gt;

&lt;asp:Button ID="btnNewGroup" runat="server" Height="26px" 
onclick="btnNewGroup_Click" Style="margin-bottom: 0px" Text="New Group" 
ClientIDMode="Static" /&gt;

protected void btnNewGroup_Click(object sender, EventArgs e)
    {
        String t = Request.Form["Name"];
    }
</code></pre>

<p>When the user clicks the new button in the dialogue I want to take the name from the textbox and use it in my code behinds asp new button click event.</p>
