Solved

How can I open a window by clicking a selectItem?

Posted on 2008-10-09
1
520 Views
Last Modified: 2013-11-24
Using JSF, I want the app to open a different window when a choice is selected the choice is in a selectItem tag. How can I do this?
0
Comment
Question by:daraii
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 14

Accepted Solution

by:
Farzad Akbarnejad earned 500 total points
ID: 22700600
Hello,
Here is a sample code. All you need is that open new windows using java script in onchange event.

-FA

<t:selectOneMenu style="width:40px" value="#{item.regPriority.id}"
       onchange="window.open('InsuredPicker.jsf?rel_type=1', 'Window Title','status=1,height=400,width=600,top=0,left=0, resizable = 0' );" >
   <f:selectItems value="#{sendRegisteredRequestController.priorities}" />
</t:selectOneMenu>

Open in new window

0

Featured Post

[Webinar] Learn How Hackers Steal Your Credentials

Do You Know How Hackers Steal Your Credentials? Join us and Skyport Systems to learn how hackers steal your credentials and why Active Directory must be secure to stop them. Thursday, July 13, 2017 10:00 A.M. PDT

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

What is Node.js? Node.js is a server side scripting language much like PHP or ASP but is used to implement the complete package of HTTP webserver and application framework. The difference is that Node.js’s execution engine is asynchronous and event…
JavaScript has plenty of pieces of code people often just copy/paste from somewhere but never quite fully understand. Self-Executing functions are just one good example that I'll try to demystify here.
Viewers will learn one way to get user input in Java. Introduce the Scanner object: Declare the variable that stores the user input: An example prompting the user for input: Methods you need to invoke in order to properly get  user input:
The viewer will receive an overview of the basics of CSS showing inline styles. In the head tags set up your style tags: (CODE) Reference the nav tag and set your properties.: (CODE) Set the reference for the UL element and styles for it to ensu…
Suggested Courses

627 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question