Open Google Calendar in a new tab

350 Views Asked by At

I'm developing a project using java and jsf. I am trying to open Google Calendar when the user clicks on a commandLink but I have no clue about how to do it.

Does anyone knows how can I handle this?

Thanks in advance

1

There are 1 best solutions below

2
DMC19 On

You can use a method like this:

public void goTo(){
  ExternalContext externalContext = FacesContext.getCurrentInstance().getExternalContext();
  externalContext.redirect("YOUR URL");
}