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.

I would like to import an rss feed into filemaker

Featured Replies

  • Newbies

Would it be possible to for me to piggyback on this post? I’m new and I don’t know all the forum etiquette. Please let me know if I should post this elsewhere.

 

I would like to import an rss feed into filemaker. I understand that I need a xslt file to transform the data into something that filemaker understands. And I found some xslt templates online, but I’m not very knowledgeable about xslt, and I can’t figure out how to make them work for my situation. Would anyone be able to help me with this? Thanks so much in advance.

 

This is an example of the source rss: http://www.sierranevada.com/downloads/formstack-test-rssfeed.xml

This is my attempt at xslt. As you can see, not very good: http://www.sierranevada.com/downloads/formstack-rss-transform-test.xslt

 

-Andrew

It would have been better to open up a new thread, as these two problems are unrelated. Perhaps one of the moderators will take care of that for you.

 

You also need to clarify what exactly do you want to import from the feed (what are your target Filemaker fields). If all you want to import is the two fields shown in your attempt (title and link), then this is easy - try:

<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="xml" version="1.0" encoding="utf-8" indent="yes"/>

<xsl:template match="/">

<FMPXMLRESULT xmlns="http://www.filemaker.com/fmpxmlresult">
<ERRORCODE>0</ERRORCODE>
<PRODUCT BUILD="" NAME="" VERSION=""/>
<DATABASE DATEFORMAT="" LAYOUT="" NAME="" RECORDS="" TIMEFORMAT=""/>

<METADATA>
    <FIELD NAME="Title" TYPE="TEXT" EMPTYOK="YES" MAXREPEAT="1"/>
    <FIELD NAME="Link" TYPE="TEXT" EMPTYOK="YES" MAXREPEAT="1"/>
</METADATA>

<RESULTSET FOUND="">

<xsl:for-each select="rss/channel/item">
<ROW MODID="" RECORDID="">
    <COL><DATA><xsl:value-of select="title"/></DATA></COL>
    <COL><DATA><xsl:value-of select="link"/></DATA></COL>
</ROW>
</xsl:for-each>

</RESULTSET>
</FMPXMLRESULT>

</xsl:template>
</xsl:stylesheet>

If, OTOH, you plan on importing anything from the <content:encoded> section, that won't be easy at all  because the feed providers have chosen (most unwisely!) to embed the payload as CDATA, thus making it unparsable as XML - leaving parsing as text as the only option.

Edited by comment

  • Author
  • Newbies

Worked perfectly! The piece that I was really not understanding was:

<xsl:for-each select="rss/channel/item">

Many thanks for your help!

 

-Andrew

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.