http://forum.umbraco.org/yaf_postst5455_content-from-Filemaker-database-via-Net.aspx )</p>;
<p style="font-family: Arial, Helvetica, sans-serif; color: #333333; font-size: 14px; margin-top: 7px; margin-bottom: 15px; line-height: 18px; white-space: pre-wrap; word-wrap: break-word;">But now I need to get the fieldsname from some related records in a portal. When I connect to Filemaker and get the full xml everything is fine, but I cant get them with the simpleXml.xsl? I have tried to change the .xsl and I can get the content but not the name of the field. Any suggestions??</p>
<p style="font-family: Arial, Helvetica, sans-serif; color: #333333; font-size: 14px; margin-top: 7px; margin-bottom: 15px; line-height: 18px; white-space: pre-wrap; word-wrap: break-word;">I have included my version of simpleXml.xsl
xslt/xml from filemaker - v2 (now readable)
http://forum.umbraco.org/yaf_postst5455_content-from-Filemaker-database-via-Net.aspx )</p>; <p style="font-family: Arial, Helvetica, sans-serif; color: #333333; font-size: 14px; margin-top: 7px; margin-bottom: 15px; line-height: 18px; white-space: pre-wrap; word-wrap: break-word;">But now I need to get the fieldsname from some related records in a portal. When I connect to Filemaker and get the full xml everything is fine, but I cant get them with the simpleXml.xsl? I have tried to change the .xsl and I can get the content but not the name of the field. Any suggestions??</p> <p style="font-family: Arial, Helvetica, sans-serif; color: #333333; font-size: 14px; margin-top: 7px; margin-bottom: 15px; line-height: 18px; white-space: pre-wrap; word-wrap: break-word;">I have included my version of simpleXml.xsl
<?xml version="1.0" encoding="UTF-8"?> <?xslt-cwp-query params="-grammar=fmresultset"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:a="http://www.filemaker.com/xml/fmresultset" exclude-result-prefixes="a"> <xsl:output method="xml" encoding="UTF-8" /> <xsl:template match="/"> <xsl:element name="root"> <xsl:for-each select="a:fmresultset/a:resultset/a:record"> <xsl:element name="record"> <xsl:for-each select="a:field"> <xsl:element name="{@name}"> <xsl:value-of select="a:data" /> </xsl:element> </xsl:for-each> </xsl:element> </xsl:for-each> <xsl:call-template name="related" /> </xsl:element> </xsl:template> <xsl:template name="related"> <xsl:element name="relatedset"> <xsl:for-each select="a:fmresultset/a:resultset/a:record/a:relatedset/a:record"> <xsl:element name="record"> <xsl:for-each select="a:field"> <xsl:element name="{name()}"> <xsl:value-of select="a:data" /> </xsl:element> </xsl:for-each> </xsl:element> </xsl:for-each> </xsl:element> </xsl:template> </xsl:stylesheet><xsl:element name="{@name}"> instead of <xsl:element name="{name()}"> but then I dont get any output.</span>
Here is the xml I get
<root> − <record> <filename /> <filepath /> − <title> <span style="white-space: pre;"> </span><!-- text --> </title> − <text> <span style="white-space: pre;"> </span><!-- text --> </text> <releasedatetxt> 03032009 </releasedatetxt> <releasedate> 03/03/2009 </releasedate> <zc_year_n> 2009 </zc_year_n> <zc_pkey_n> 323 </zc_pkey_n> − <text_css> <span style="white-space: pre;"> </span><!-- textCss --> </text_css> </record> − <relatedset> − <record> <field> <span style="white-space: pre;"> </span><!-- text--> </field> − <field> <span style="white-space: pre;"> </span><!-- text--> </field> </record> − <record> <field> <span style="white-space: pre;"> </span><!-- text--> </field> − <field> <span style="white-space: pre;"> </span><!-- text--> </field> </record> </relatedset> </root>And here the XML I want - it is the part with <relatedset> that is giving problems.
<relatedset count="2" table="attachments_skolebreve"> − <record mod-id="0" record-id="532"> − <field name="attachments_skolebreve::fileName"> <data> <!-- text --> </data> </field> − <field name="attachments_skolebreve::bin"> − <data> <!-- text --> </data> </field> </record> − <record mod-id="0" record-id="533"> − <field name="attachments_skolebreve::fileName"> <data> <!-- text --> </data> </field> − <field name="attachments_skolebreve::bin"> − <data> <!-- text --> </data> </field> </record> </relatedset>Anybody who can point me in the right direction?
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.