jQuery Load with jQuery Tabs - Unobtrusive Validation

193 Views Asked by At

I am using jQuery Tabs and I am loading the tab pages using the tabsbeforeactivate event, so that I only load contents when needed through Ajax.

I am facing difficulties since I need to manually enable Unobrusive Validation after injecting the respective contents. I am using the $('#tabs-0').load and the $.validator.unobtrusive.parse($(result)); when completed.

I don't know why but I still don't get the Unobtrusive Validation.

Thanks a lot

1

There are 1 best solutions below

0
On

I was able to do it using the Load Callback Function.

When the Load mehtod is completed I call the:

$.validator.unobtrusive.parse($(result))

http://api.jquery.com/load/