Graphics

 View Only
  • 1.  Return Empty Field when XML data not present?

    Posted 06-02-2022 13:09
    I'm trying to tag leaderboards to an XML file that is generated by a scoring server, and the way this server generates files is to delete XML tags when there is no data present in them.  I've tried tagging to where these fields should be if there is data there and selecting return empty on failure, but I'm getting phantom data from somewhere instead of the blank field like it should be.

    ------------------------------
    Stephen Treiber
    Feature Productions Inc.
    ------------------------------


  • 2.  RE: Return Empty Field when XML data not present?

    Ross Staff
    Posted 06-02-2022 14:00
    Hi Stephen, 

    I hope I'm understanding your problem correctly, let me know if I am misunderstanding.

    You can create an XSLT file to filter through your XML, grab the specific tags you need and attach that to your DataLinq configuration. This way you can have XPression look for the filtered tags instead of the original XML that may delete some tags. If a tag doesn't exist in the XML, the XSLT should find nothing and XPression should then show a blank field.

    ------------------------------
    Sven Whitesell
    Product Specialist
    Ross Video
    ------------------------------



  • 3.  RE: Return Empty Field when XML data not present?

    Ross Staff
    Posted 06-03-2022 06:31
    Also, if it's always the same tag or a small list you could use VL or script to do a replace "whatevercharacter" with ""

    ------------------------------
    Simon Redmile
    Senior Graphic Programmer & Designer
    Ross Video
    Bristol United Kingdom
    ------------------------------



  • 4.  RE: Return Empty Field when XML data not present?

    Posted 06-06-2022 14:23
    Would you be able to point me to a tutorial on creating XLST files for XPression?  I have zero experience with scripting or XLST.

    --
    Stephen Treiber
    403-942-6655 - Office
    403-363-7730 - Cell







  • 5.  RE: Return Empty Field when XML data not present?

    Ross Staff
    Posted 06-07-2022 09:37
    Hi Stephen,

    XSLT doesn't require any scripting. It is essentialy another xml file, that is used to filter through a different xml file to pick out the relevant information. This file would be attached to the DataLinq server that is receving the XML data. You should take a quick look at this website to get a better explination on how it works: https://www.w3schools.com/xml/xsl_intro.asp. 

    I've been assuming you are using DataLinq to bring the score data into XPression. Do you know which DataLinq source is being used for connecting to the scoring data? Not all the sources have the capability to use XSLT files. If it's one that can't do it, then I'll come up with some visual logic for you to force the text to show as blank.



    ------------------------------
    Sven Whitesell
    Product Specialist
    Ross Video
    ------------------------------