Skip to main content
vze26m98
Known Participant
January 18, 2012
Question

The Perils of InDesign XSLT

  • January 18, 2012
  • 1 reply
  • 3329 views

Hi all-

Not much of a question; if I have one it's "what's up with the XSLT processor that InDesign uses"?

After several days of work with it, I'm convinced that it can't handle namespaces correctly, the most spectacular example being this attribute it managed to generate:

xmlns="<DUo=>a7n)"

Perhaps worse though, are the times when xmlns is given the value of "7" or something, the XSLT or XML processor dies quietly, and InDesign can import no more until the application's been restarted.

I thought this might be something I'm doing wrong, but I compared my results to the Sablotron processor for WIndows that's still kicking around the Internet, and also the version that's available via Ubuntu Lucid long-term support. Both are pretty happy with the coding I've done.

Why am I messing around with namespaces? Well, Filemaker. Their database export ungraciously make the default namespace "http://www.filemaker.com/fmpxmlresult", so you have to deal with that if you want to do anything.

But enough flaming. I'd love to hear from anyone who's doing something reasonably complex with XSLT and InDesign. Maybe it's just OSX Lion here that's making Adobe's work seem so old.

Best wishes, Charles

This topic has been closed for replies.

1 reply

Inspiring
January 18, 2012

It's been awhile since I wrote xslt for InDesign to use on import, but I remember being underwhelmed. (I talked about this in the same non-specific way in this thread.) I don't remember having problems with namespaces though. I'd be happy to try your transform and import here if you want.

I would encourage you to file bugs. I don't think InDesign's xml capabilities have been updated in quite some time. Judging from posts on this forum, it is still in heavy use.

You could always use doScript and do shell script inside an Applescript to drive a command-line processor like the open-source Saxon and import the result of that.

Jeff

John Hawkinson
Inspiring
January 18, 2012

You could always use doScript and do shell script inside an Applescript to drive a command-line processor like the open-source Saxon and import the result of that.

Or just plain xsltproc(1) that ships with the OS...

vze26m98
vze26m98Author
Known Participant
January 19, 2012

Thanks to you both for your kind replies.

My solution needs to be cross-platform, so working with what InDesign provides makes that simpler.

I now have working XSLT that isn't too ugly to look at, and produces exact copies of the required interchange XML between Filemaker and InDesign, which enables me to see trouble with a Diff tool.

I'll file a bug report. Maybe some Adobe tech can take the source package from the Ubuntu repository and update InDesign.

Best, Charles