Is it possible to set a <a href />around my <f:selectItem itemLabel="label" /> where my link text is the itemLabel?
I’m using the plain sun components.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
The desired result is not possible in HTML. You’ll need to add a shot of JavaScript for this.
Where
bean.getLinks()returns aList<SelectItem>with a fullworthy URL as item value. If you want to show the link as both value and label, just use theSelectItemconstructor taking a single argument.If you want to hardcode them in the view, then you can of course grab
f:selectItem: