Friday, March 30, 2012

how to go to non-gwt page from gwt app

i have gwt app that if the user fail the authentication, it kick the
user out to login page, which is a non-gwt page, what the function
that i can use to do the redirection on the client side?

here is my code:

userService.getCurrentUser(new AsyncCallback<User>() {
public void onFailure(Throwable exception) {
Window.alert(exception.getMessage());
GWT.log("getCurrentUser failed", exception);

//go to home.html, how?
}

public void onSuccess(User result) {
m_eventBus.fireEvent(new LoginEvent(result));
}
});

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 google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to google-web-toolkit+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.

No comments:

Post a Comment