【发布时间】:2015-08-08 13:57:27
【问题描述】:
我有两个<o:graphicImage> 来显示存储的图像和一个虚拟图像(如果没有图像)。实际上,存储图像的大小可以为零。如果是,则渲染第一个<o:graphicImage,但图像为空且未正确渲染。
<o:graphicImage id="image" alt="Image"
lastModified="#{userProfile.user.lastModified}"
rendered="#{not empty images.getImage(userProfile.user.id)}"
value="#{images.getImage(userProfile.user.id)}"
<o:graphicImage name="images/profile.png" width="125"
rendered="#{empty images.getImage(userProfile.user.id)}" />
如果用户图像为空或长度/大小为 0,如何显示虚拟图像?
【问题讨论】:
标签: jsf omnifaces graphicimage conditional-rendering