That's excellent, although I had to use bind instead of append... and
I have no idea why :)
I have another question, if I wanted to initialize another plug in
after the datePicker, how would that be?
this is my current code:
$("#loadformdiv").load("forms.asp?form=2", function(){
$(this).bind(
$('.date-picker').datePicker()
)
});
and I want to also start:
$('#contactform').ajaxForm({
beforeSubmit: function(a,f,o) {
o.dataType = $('#uploadResponseType')[0].value;
$('#uploadOutput').html('Submitting...');
},
success: function(data) {
var $out = $('#contactdiv');
$out.html('Form success handler received: <strong>' +
typeof data + '</strong>');
if (typeof data == 'object' && data.nodeType)
data = elementToString(data.documentElement, true);
else if (typeof data == 'object')
data = objToString(data);
$out.append('<div><pre>'+ data +'</pre></div>');
}
})
Thank you in advance!