We negotiated with my boss the following workflow:
The backoffice of our site is about pupils (children).
Now we at the page for entering contract data for a specific pupil. This page displays (among other) a <select> with a list of people which may be kins of a child.
When we click "Add" button, an iframe inside of jQuery UI modal dialog appears. In the iframe there is an active form to enter a new kin for the pupil. Or we can select an existing kin from the list of kins and press "Edit" button, this also opens an active form inside the iframe inside a modal dialog. When a kin is added or edited the above mentioned <select> should be updated.
Now the hard part: If inside the popup in iframe the button "Save" is clicked and the saving performs successfully then the popup should close and the <select> with the list of kins on the page should be updated. But if the button "Save" is clicked and there are errors, the popup should not close and the errors should be displayed inside the iframe.
So it should behave differently on successful submit and failed submit.
How to implement it? I guess something related with AJAX, but don’t know the exact way to do this.
The workflow is not set in stone, you may advice me how to change the user experience with our site.