Posting a Dialog Form with AJAX, no page refresh, close dialog after Post

Posting a Dialog Form with AJAX, no page refresh, close dialog after Post

I have searched and tried but cannot find a way to post a form from a Popup (JQM 1.2.0).

I want to show any form errors in the popup, and close the popup on success.

Does anyone know a tutorial for this? The official JQM 2.0 Docs don't mention anything about this.