h:commandButton link

2007-10-03 Thread Wolfgang
Hi, I can use the action parameter of the h:commandButton to change to another xhtml site. But can I also link to a internet site for example google.de? Cheers Wolfgang

Re: h:commandButton link

2007-10-03 Thread Andrew Robinson
Command button passes the outcome and the action to the navigation handler. If you want it to work with external URLs, you would have to code that into your navigation handler. Instead, the best solution is to send a redirect to the external URL. Navigation really should be reserved for

Re: h:commandButton link

2007-10-03 Thread wkluge
Hi Andrew, I tried to code the url directly in the navigation handler. I tried several combinations etc. but it does not really work and I guess your right that the navigation should only be used by inter-application navigation! Furthermore I don't understand what you mean with send a redirect to

Re: h:commandButton link

2007-10-03 Thread simon
To generate a plain link that points to another site, use h:outputLink. To send a redirect from an action method, do something like this: public void doSomething() { FacesContext.getCurrentInstance(). getExternalContext().redirect(http://google.de;); } Regards, Simon On Wed,

h:commandButton link to new site

2007-09-06 Thread Wolfgang
Hi, is it possible to have a link to new site behind the commandButton? Cheers Wolfgang

Re: h:commandButton link to new site

2007-09-06 Thread simon
On Thu, 2007-09-06 at 16:19 +0200, Wolfgang wrote: Hi, is it possible to have a link to new site behind the commandButton? Not directly. A commandButton causes a form submit, and that is always going to go back to the original server. Why would you want this? Linking to a new site is not