Dave,

You will need to set the 'success' callback in your ajaxForm options,
in your function you would then set the h1 tag to what ever your input
fields val was.

$('#myForm1').ajaxForm({
     success:     function(responseText, statusText){
          $('h1').html($('#title').val());
     }
});

Obviously you need to be more specific then what i have there but
that's the general idea. You could also have the server respond back
with the title ... and use the responseText instead of the value
straight from the form.

See here for more information [ http://malsup.com/jquery/form/#code-samples
] on the form plugin.

Chris

On Sep 23, 5:05 pm, "Dave Maharaj :: WidePixels.com"
<d...@widepixels.com> wrote:
> I am using the jquery.form.js script and submit a form just fine.
>
> My Question is how can update an additional div after the form is sumbitted.
>
> Example
>
> <h1>title here </h1> => might say something like Edit you Green Earth Post
>
> Page content code.....
>
> <div id='formHere'>
> form.....
> </div>
>
> So the form loads in <div id='formHere'>, submit and fades out new content
> is replaced where the form was staright forward stuff. But the form has a
> title textfield which is where the <h1> tag is so when they submit the form
> if they changed the title i want the new title to be display there.
>
> So if they change the title from Green Earth Post to Enviro Plan in the form
> the <h1> tag will now show Enviro Plan.....
>
> Dave

Reply via email to