Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

Hello all,

 

I'm grafting an XSL to generate text in Final Cut Pro 7, it works fine except I need the carriage return "
"

 

Like so

 

<value>Client:&#13;Agency:&#13;Product:&#13;Clock Number:&#13;Title:&#13;Duration:&#13;Aspect:&#13;Audio Type:&#13;Language:</value>

 

Trouble is that the result is: "&amp #13;"

 

I've read in Filemakers "Developing FileMaker XSLT stylesheets" PDF (Page 69) that I need to use the function: fmxslt:break_encode(String value)

and to disable-output-escaping attribute of the <xsl:value-of> and <xsl:text> elements set to “yes” (disable-output-escaping="yes").

 

Could someone please explain to me with an example of how I could formulate this.

 

Regards

Ian

I am not sure I understand the context here. Is this part of your XSLT stylesheet?

<value>Client:&#13;Agency:&#13;Product:&#13;Clock Number:&#13;Title:&#13;Duration:&#13;Aspect:&#13;Audio Type:&#13;Language:</value>

And you are using this to export your records from Filemaker Pro?

 

 

If yes to both, what is the actual output you are hoping to get out of this?

  • Author

It's yes to both

 

This will/does generate a text slate in a FCP timeline at the moment it returns: "A CompanyA AgencyA ProductA Clock Number" instead of:

 

A Company

A Agency

A Product

A Clock Number

 

Because the resulting XML has "&amp #13;" instead of "&#13;". Hence I need to I need to use the function: fmxslt:break_encode(String value)

 

 

 

What is the  output method of your stylesheet (if it's not too big, why don't you just post the whole of it).

 

BTW, there is no fmxslt:break_encode() function in this (exporting) environment. The fmxslt extension functions are only available in CWP.

 

 

---

Ahm, one more thing: why do you expect:

 

A Company

A Agency

A Product

A Clock Number ...

 

and so on, when your code says

 

Client

Agency

Product ...

 

Those are literal text strings, not field values.

  • Author

Sorry yes I was using it as an example.

 

One thing before I post it, how do I generate the box to place the code in?

Select the text and click the code <> button. However, before you do that, see if this works for you: 

<xsl:text>Client:&#13;Agency:&#13;Product:&#13;Clock Number:&#13;Title:&#13;Duration:&#13;Aspect:&#13;Audio Type:&#13;Language:</xsl:text>
  • Author

This is my Calc field in FMP

Client & "&#13;" & Agency

This is my XSL:

<name>Text</name>
<effectid>Text</effectid>
<effectcategory>Text</effectcategory>
<effecttype>generator</effecttype>
<mediatype>video</mediatype>
<parameter>
<parameterid>str</parameterid>
<name>Text</name>
<value>
<xsl:for-each select="fmp:COL[1]">
<xsl:value-of select="fmp:DATA"/>
</xsl:for-each>
</value>
</parameter>
<parameter>

This is the result XML:

<effectcategory>Text</effectcategory>
<effecttype>generator</effecttype>
<mediatype>video</mediatype>
<parameter>
<parameterid>str</parameterid>
<name>Text</name>
<value>Swiss Tourism&amp;#13;Online Video 46 AG</value>
</parameter>
<parameter>

This is what it should look like:

<effectcategory>Text</effectcategory>
<effecttype>generator</effecttype>
<mediatype>video</mediatype>
<parameter>
<parameterid>str</parameterid>
<name>Text</name>
<value>Swiss Tourism&#13;Online Video 46 AG</value>
</parameter>
<parameter>

Instead of:

<value>
<xsl:for-each select="fmp:COL[1]">
<xsl:value-of select="fmp:DATA"/>
</xsl:for-each>
</value>

use:

<value>
   <xsl:value-of select="fmp:COL[1]/fmp:DATA" disable-output-escaping="yes"/>
</value>

BTW, you don't need the calculation field for this. You can achieve the same result by:

<value>
   <xsl:value-of select="fmp:COL[1]/fmp:DATA"/>
   <xsl:text disable-output-escaping="yes">&amp;#13;</xsl:text>
   <xsl:value-of select="fmp:COL[2]/fmp:DATA"/>
</value>

where COL[1] is Client and COL[2] is Agency.

  • Author

Hey perfect, it works great.

 

I did start with the separate COL[1] and COL[2] format, but I found it more flexible to use a calc field in FMP

 

Thanks a lot

Ian

I found it more flexible to use a calc field in FMP

 

My policy is to push everything that serves only the export out to the XSLT stylesheet.

  • Author

Maybe I should have said in this instance, I've done a couple of other XSLT stylesheets where it would have been impossible to use just one calc field.

Create an account or sign in to comment

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.