jsf - how to open page in new window NOT tab using h:commandLink? -


using primefaces 4.0 , jsf 2.2.

i send visitor page in new window (not tab). landing page jsf page called grade.xhtml

i tried:

<h:commandlink value="ok" onclick="window.open('grade.html', 'newwindow','width=300, height=300'); return false;"/> 

this gets 404. happening client side grade.html doesn't generated grade.xhtml. how should do?

note: if put onclick="window.open('grade.xhtml', 'newwindow','width=300, height=300'); return false;" page open, jsf (xhtml code) not html version shows up.

try this:

<h:commandlink value="ok" action="grade.xhtml" target="_blank"/> 

look example here: when click on link should open in same new window in jsf, primefaces


Comments

Popular posts from this blog

apache - Remove .php and add trailing slash in url using htaccess not loading css -

javascript - jQuery show full size image on click -