Jump to content
Sign in to follow this  

XML/XSL Field IF statement

Recommended Posts

I am new to XML/XSL and am trying to get an if statement to work but I can't seem to get the language right. I want to show a link based on the contents of a field in my database. ie: if there is no data in the field I don’t want a link (or image to the link) to be displayed but if there is any data in the field (the data in the field would be a link)I want it to be displayed as a link.

Any help would be greatly appreciated. I have found this forum to be very helpful in the past.

Share this post

Link to post
Share on other sites

The statement should be like that

  <-- whatever -->

This assumes you have only one record in your found set; otherwise you'll have to use more sophisticated XPath expression to get to the field.

Share this post

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • Who Viewed the Topic

    1 member has viewed this topic:
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.