Backing bean String[] access in JSF?

First of all, JSTL and JSF doesn't work seamlessly together in sync as you would expect from the order in the coding. It's more so that JSTL runs first before JSF kicks in. Virtually, JSTL processes the entire page from top to bottom first and then hands the generated output (thus without any JSTL tags, but with its generated output) over to JSF which in turn processes the entire page from top to bottom again As the h:dataTable hasn't generated any rows yet at the moment the JSTL runs, you aren't going to see anything from the c:forEach inside a h:column Rather use the JSF-supplied iterating components, such as Tomahawk's t:dataTable or RichFaces a4j:repeat or Facelets ui:repeat or maybe even a nested h:dataTable.

First of all, JSTL and JSF doesn't work seamlessly together in sync as you would expect from the order in the coding. It's more so that JSTL runs first before JSF kicks in. Virtually, JSTL processes the entire page from top to bottom first and then hands the generated output (thus, without any JSTL tags, but with its generated output) over to JSF which in turn processes the entire page from top to bottom again.As the h:dataTable hasn't generated any rows yet at the moment the JSTL runs, you aren't going to see anything from the c:forEach inside a h:column.

Rather use the JSF-supplied iterating components, such as Tomahawk's t:dataTable, or RichFaces' a4j:repeat, or Facelets' ui:repeat, or maybe even a nested h:dataTable.

I would guess the problem stems from using . JSTL tags don't always play well with JSF tags as they are not evaluated at the same time. Try.

I've tried tags and it causes my browser to hang. I've had the same trouble with other richfaces tags but that's another story. – Mark Lewis Jan 28 '10 at 0:56 That seems unlikely.

Were you repeating over an infinite loop? – Naganalf Jan 28 '10 at 1:05 No, I've got the console outputting the contents (listing above) showing it should only have 3 entries. I wondered though, as I'm attempting to output 7 feeds worth of rows, for some of which there are Ftq arrays with no entries, would this cause a problem?

Do I need to pad the String Ftqs with something in this case? – Mark Lewis Jan 28 '10 at 12:37.

I remember having a similar problem due to using all caps in the name of the getter/field or like your case FTQs, have you tried changing item. FTQs to item. FTQs or even renaming your getter/setter to Ftqs instead and using item.

Ftqs?

Thanks for the response. The editor had omitted highlighting the getter and setter for the FTQar in the TaskListData class. I've done the edit now.

I should ask though, the getter/setter is not all caps - but I know what you mean - as in mainly caps. I'll try getFtqs and setFtqs when im back in the office. – Mark Lewis Jan 28 '10 at 8:45 OK, for completeness, the capitalisation in eclipse 3.4 and tomcat 6, jre 1.6 didn't make any difference.

– Mark Lewis Jan 28 '10 at 12:32.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions