Jump to content

XML export unwanted code


This topic is 3093 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • Newbies

Hi i made a export from my calculated xml data. Using a simple stylesheet to

export my calculated field and clean up the FMP xml code.

<?xml version="1.0" encoding="utf-8"?>

<xsl:stylesheet version="1.0"

xmlns:xsl="http://www.w3.org/1999/XSL/Transform"

xmlns:fmp="http://www.filemaker.com/fmpxmlresult"

exclude-result-prefixes="fmp">

<xsl:output method="xml" version="1.0" encoding="UTF-8" indent="yes"/>

<xsl:template match="/">
<xsl:value-of select="." disable-output-escaping="yes" />

</xsl:template>

</xsl:stylesheet>

I only need 1 field to be exported. That contains all my xml data.

When it is done, in the xml the xml start with a 0. Therefore the xml is not working.

It is my first xml export project. What do i do wrong ?

Edited by PaSavICT
Link to comment
Share on other sites

Change this:

<xsl:value-of select="." disable-output-escaping="yes" />

to:

<xsl:value-of select="fmp:FMPXMLRESULT/fmp:RESULTSET/fmp:ROW/fmp:COL/fmp:DATA" disable-output-escaping="yes" />

Otherwise you are outputting the string-value of the entire / root node - and this includes the value of ERRORCODE.

Link to comment
Share on other sites

This topic is 3093 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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

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