There is only a RENDER_RESPONSE phase for the initial request in a phase listener, but all of the phases in a postback.
Does that help? On Tue, Apr 19, 2016 at 2:09 PM, fischman_98 <mfisc...@powerconsultantsinc.com> wrote: > *FYI*: When added the call to addResource in encodeEnd method of a Custom > Component it works on both /*initial request*/ and /*postback */. > > Here's the initial request; > > RESTORE_VIEW(1) :: Before > RESTORE_VIEW(1) :: After > RENDER_RESPONSE(6) :: Before > *AddResource Here!* > RENDER_RESPONSE(6) :: After > > Same code I had in the listener in the encodeEnd; > > AddResource ar = AddResourceFactory.getInstance(facesContext); > ar.addInlineScriptAtPosition(facesContext, AddResource.HEADER_BEGIN, > "window.open()"); > System.out.println("AddResource Here!"); > > So....any thoughts why it works from the component and not from the phase > listener? > > Thanks. > > > > > -- > View this message in context: > http://myfaces.10567.n7.nabble.com/addResource-to-add-CSS-JS-Only-working-on-PostBack-tp121593p121619.html > Sent from the MyFaces - Users mailing list archive at Nabble.com.