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.

Attaching a style sheet?

Featured Replies

Hi there,

I am pretty new to XML / XSL so apologies if this is a dumb question.

I have used an XSL file to output data as XML from FMP8 in fmpxmlresult format.

The XSL file I am using is this: -

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

xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.1" exclude-result-prefixes="fmp">

It seems to work ok and produce an output file that looks like this: -

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

222

286

242

Quite simple!

I want to format the output using a CSS (or XSL) style sheet which I would normally do by adding the following line to the top of the XML file.

<?xml-stylesheet type="text/css" href="housepoints.css"?>

But if I include that line in my XSL file, it does not appear in the output (XML) file.

Can anyone suggest what I am doing wrong here please?

Thanks in advance,

Codeus

<?something?> is a processing instruction, and, hence, will be processed by the XSLT processor :)

That's why it does not appear in your XML result.

There is a special XSLT command for generating processing instructions, and guess what?, it's called

So you need to add the following to your XSLT code




  type="text/css" 

  href="housepoints.css"



See also http://www.dpawson.co.uk/xsl/sect2/N6145.html#d8258e133

  • Author

Thanks Martin,

That hit the spot perfectly. I guessed that it was interpreting my <?something?> command too early but was unaware of the command.

Your response saved me a ton of time so thanks again!

Codeus

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.