[eluser]Ajaxboy[/eluser]
1. These broad questions, and there are many ways of accomplishing the objective you are after.
Generally speaking, instead of redirecting to an error page, generally in the ajax framework you may display error messages on the screen eg: $ajax->error("Error Message Here") or warnings; $ajax->warning("Warning Message Here") ;
2. If you actually wish to redirect to the base url you can do: $ajax->location(base_url());
Quote:So my question is... Can I run that function via AJAX, load the views for the errors if necessary(in an overlay) and here is the kicker, on success, open a comment form in an overlay to submit a comment using all of the validation data I collected when the link was first clicked?
So now your question relates to the validation plugin...
Since the form doesn't exist on page load, You would need to trigger the validate plugin from the ajax response and add validation to that form just after you run the $ajax->overlayContent() command which displays the form.
just make sure you run the validate plugin command after the overlayContent that displays the form and not before to avoid retroactive action.