4 Replies Latest reply on Dec 3, 2011 9:39 AM by backhand1955

    creating xml files in Indesign


      We are a small family run typesetter. Our biggest client has now decided he wants the finished product as an XML file as well as a PDF.

      They have provided a DTD, which means nothing to us.

      Any help would be much appreciated.


        • 1. Re: creating xml files in Indesign
          [Jongware] Most Valuable Participant

          If this is your first foray into the fractured realm of XML, this post won't help by much. Try Google - a first glance shows Adobe's own documentation (which I personally never read, actually), a lecture by Cari Jansen, and even a YouTube video. Use these to familiarize yourself with the basic concepts first.


          The good news is: YES it's perfectly possible to export your formatted text as XML.


          The very easiest way would be to have InDesign automatically fill in XML tags for each paragraph and character style export right away. It does require you -- the text formatter -- to strictly and esclusively use paragraph and character styles to format, but then again that should be virtually a requirement for ALL the work one does in InDesign. Another requirement is that the supplied DTD allows this.


          On its own or in combination with the above, you can manually tag items as well as add structural elements in the document. That's what the Structure pane is for, the XML view of your document that appears on the left side of the screen if you call it up from the View menu. (Try it -- although you'll see nothing of interest because, presumably, none of your documents are tagged.)


          I make extensive use of XML tagging since a lot of my work is going straight into a database, in a *very* specific format which is not easily applied to native ID files. So I tag only the items that are strictly required and use a Javascript to fish these items out of the running text, clean them up a bit (unfortunately, ID may throw in one or two highly incompatible codes into a supposedly clean export), and write them into a file in the custom format for this client.

          • 2. Re: creating xml files in Indesign
            John Hawkinson Level 5

            You should probably tell him that it will cost you a lot more to do it. I realize this is your biggest client, but it's plausibly going to double or triple your time.


            What DTD is it? It is it a standard one? The first few lines should help you identify it.


            Prepare for a world of hurt, I'm afraid. Most fundamentally, the issue is that every piece of content in InDesign now has to be designated/tagged for XML export to work properly. This can be via paragraph styles, or via manual tagging. Either way, it can be awfully error-prone and potentially labor-intensive, especially if you don't use scripting automation.


            Is your client familiar with InDesign's XML capabilities? They may or may not be a good match for his needs...

            • 3. Re: creating xml files in Indesign
              backhand1955 Level 1



              Thanks for your reply. It does confirm what we feared - that this is not a simple thing to achieve by any means!


              We will continue to explore all avenues and try to remain optimistic.


              Best wishes,



              • 4. Re: creating xml files in Indesign
                backhand1955 Level 1



                Thanks for your response. It does kind of confirm our fears - that creating XML files from InDesign is neither simple or straightforward. At the end of the day if our client is using this as a cost-cutting exercise (which I suspect they are), then we may be best pulling out now rather than spending valuable time and resources pursuing the possibility of going down this route when they are not prepared to pay more for the end product.


                Once again, thanks alot for your prompt response and suggestions.


                Best wishes,