Form Page:
<form id="htmlForm" action="html-echo.asp" method="post">
    Name: <input type="text" name="name" value="Hello HTML" />
Comment: <input type="text" name="message" value="Hello HTML" />
    <input type="submit" value="Echo as HTML" />
</form>

JAVAscript:
$(document).ready(function() {
    $('#htmlForm').ajaxForm({
        target: '#htmlExampleTarget',

        success: function() {
            $('#htmlExampleTarget').fadeIn('slow');
        }
    });
});

ASP page:
if name = "" and message = "" then
response.Write("Please enter your name and a comment")
else
response.Write("Success")

What i want is to know how to disable the form if the div displays
"Success"


On Jul 16, 7:27 pm, Theodore Ni <zyl...@gmail.com> wrote:
> In addition to trying Cesar's suggestion, you should give us some more code
> details and context. You can do this sort of check on a number of events,
> including onclick and onsubmit, or whenever your div is updated.
> Ted
>
> On Thu, Jul 16, 2009 at 6:41 PM, Cesar Sanz <the.email.tr...@gmail.com>wrote:
>
>
>
> > you can check the message in the onclick event...
>
> > ----- Original Message ----- From: "icuucme" <deron.tava...@gmail.com>
> > To: "jQuery (English)" <jquery-en@googlegroups.com>
> > Sent: Thursday, July 16, 2009 4:37 PM
> > Subject: [jQuery] Re: Disabling Button in jQuery HTML Form Plugin
>
> > still looking for help with this...thanks
>
> > On Jul 8, 1:36 pm, icuucme <deron.tava...@gmail.com> wrote:
>
> >> I am currently using this pluginhttp://
> >>www.malsup.com/jquery/form/#code-samples
> >> (HTML) to display a div with content, depending on what is entered.
>
> >> Is there a way to disable the submit button if the div contains a
> >> certain message?

Reply via email to