0
votes

I have tried looking, and its just getting silly.

I am running Glassfish 3.1.1,
JSF version 2
and netbeans 7.0.1

And the following will not work, at all.

< html xmlns="http://www.w3.org/1999/xhtml" xmlns:c="http://java.sun.com/jsp/jstl/core">

snipped

< c:remove var="test" scope="session"/>

I know it must be something stupid, this is what netbeans keeps saying:

The component library Jstl Core doesn't contain component

And in every JSTL tag library I have checked, it does!

1

1 Answers

1
votes

The <c:remove> is originally in the JSTL library for the legacy JSP view technology. Facelets, the successor of JSP, has only a subset of the JSTL tags redefinied (JSP tags doesn't work in Facelets, they have been ported/rewritten). The <c:remove> is not among them.

Your concrete problem has to be solved differently. As the concrete functional requirement is unclear, I can't answer that in detail. But I guess that you actually need a JSF @ViewScoped or a CDI @ConversationScoped bean and store the desired property in there. It'll then be removed when the view scope or the conversation scope ends. Those scopes are well definied and lies in between the request and session scope. See also How to choose the right bean scope?