Back

If your email is not recognized and you believe it should be, please contact us.

  • You must be logged in to reply to this topic.Login

How to create IDML package from an XML file input

Return to Member Forum

  • Author
    Posts
    • #55835
      gvdesign
      Member

      I have an XML file (this file is not an IDML structured, but has informaiton like image height, width, font, text etc.. and other template co-ordinates) and need to generate IDML file from this file. Is there a way to instruct the InDesing Server CS4/5 to generate this programatically. Is this possible through scripting?

      Any help is much appreciated.

      Thanks

      -G-

    • #55836
      jimbirk
      Member

      Hi G,

      There are a number of ways that you can do what you need. First off, I'm guessing that you are not necessarily after a script that turns arbitrary XML into IDML, but rather a script to turn your XML into an InDesign document. If you need an IDML file, the easiest course to take is to create the InDesign document, and then export IDML from it. IDML is a complex format that is not trivial to create from scratch–I'm not saying that it can't be done, it's just not super easy.

      I'm thinking that if this is just a one time thing (you will not be getting the same kind of XML files in the future), and the document isn't overly long, it might be possible that your best course of action is to create a new ID document manually using the XML file as a guide. If you will regularly be getting the same type of XML documents, then it might be worth the time and expense to create a script (or hire someone to write the script for you) to automatically create an InDesign document from the XML for you.

      FYI: Both InDesign and InDesign Server handle XML in the same way, so you do not need IDS to do what you want–the standard desktop version will do just as well as server for this task.

      I've written a number of InDesign scripts that consume XML and would be happy to help if you want to go in that direction.

      Jim Birkenseer
      https://www.premediasystems.com

    • #55838
      gvdesign
      Member

      Hi Jim

      Thanks for the reply. As you guess the conversion need to happen quite frequently and hence writing a script would be the most appropriate solution. Hence should it be and INDD file or the IDML to generate from the XML?

      Thanks

      -G

    • #55841
      jimbirk
      Member

      Hi G,

      If I were writing the script, I would have the script parse (read) the XML file that you have and generate an INDD file that represents the XML's contents. In other words, if you do not specifically need an IDML file, I would not bother creating one.

      That being said, if you have control over how the XML file is being created (I'm guessing the XML is being created from a database or a server of some kind), it might be possible to have the server generate an IDML file instead of an XML file. Having the server or database generate an IDML file would require a significant amount of work on the part of the folks that maintain the server or database (knowledge of InDesign and the IDML format will be necessary).

      So, without more information about the content being converted to an InDesign document, and since XML is much easier to create than IDML, I would stick with the XML process and create an InDesign script that parses the XML and generates an INDD from it.

      Feel free to contact me offline if you would like me to estimate the costs of such a script.

      Cheers!

      Jim Birkenseer
      https://www.premediasystems.com

Viewing 3 reply threads
  • You must be logged in to reply to this topic.
Forum Ads