Melis Posted April 28, 2005 Posted April 28, 2005 I'm trying to have a container field display it's self if there is an image file stored in it or if there isn't Tried this: [FMP-if: Child_Photo .ncn.] [/FMP-if] Didn't work Can someone help? Thanks !! P.s. "Child_Photo" is the name of the container field.
BrentHedden Posted April 29, 2005 Posted April 29, 2005 Maybe I'm missing something, but isn't that what a container field is suppose to do by default? If there is content inserted into the container, it'll show what it is (like a picture in this case). Is there something you wanted to 'show' if the container is empty? If so, then - If [ isEmpty(Child_Photo) ] Display some text in a text field like "No Picture Available" EndIf
Alderete Posted August 9, 2005 Posted August 9, 2005 My approach was to create a calculated field, cn_photo_exists_fl, which is defined as: If(IsEmpty(ec_photo_container), 0, 1) Then in the CDML, I can test on the flag field, like so: [FMP-If: cn_photo_exists_fl .eq. 1] (HTML and CDML code to display image) [/FMP-If] Works well for me, though if you have a lot of container fields, you need a corresponding lot of calculated fields...
Recommended Posts
This topic is 7115 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now