You could try checking the request's Content-Type.  GWT RPCs use
"text/x-gwt-rpc; charset=utf-8".  See the end of
com.google.gwt.user.client.rpc.impl.RemoteServiceProxy for the place where
it is declared in the client implementation.

This might be subject to change in the future, but its a pretty good
assumption that a POST with "gwt-rpc" in the Content-Type is a GWT AJAX
request.

On Wed, Dec 3, 2008 at 17:58, jvm <[EMAIL PROTECTED]> wrote:

>
> I am integrating GWT into an existing servlet-based application. The
> application's web.xml contains a set of error-page tags specifying a
> JSP to use for various error codes and exceptions.
>
> For certain kinds of errors, this error-page jsp is sent  to the GWT
> client in response to GWT ajax calls; GWT forwards the resulting HTML
> to the onFailure() method, within the exception message.  I would like
> to change the JSP to provide a more GWT-friendly response for GWT
> requests only, or change my onFailure() method to display the HTML in
> an alert popup. Does anyone have suggestions as to how to do this?
> Removing error-page is not an option.
>
> Thanks!
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to