XML Publishing with InDesign CS2+

Book description

Adobe InDesign's user documentation provides some examples of importing and formatting XML. But if you need to wrangle XML that comes from a database or website and make it look good inside an InDesign document, you'll want to dive deeper. (Note: while Adobe made significant changes to the underlying format of InDesign in CS4, the processes for consuming XML content remain similar to CS3.)

Some of the useful applications are importing database content into InDesign to create catalog pages, exporting XML that will be useful for subsequent publishing processes, and building chunks of content that can be reused in multiple publications.

In this Short Cut, we'll play with the contents of a college course catalog and see how we can use XML for course descriptions, tables, and other content. Underlying principles of XML structure, DTDs, and the InDesign namespace will help you develop your own XML processes. The Advanced Topics section gives tips on using XSLT to manipulate XML in InDesign.

Table of contents

  1. XML Publishing with InDesign CS2+
    1. About This Book and InDesign CS2/CS3
    2. A Brief Foray into Structured Content (a.k.a. XML)
    3. InDesign XML Publishing: College Catalog Case Study
      1. Data-like Content Example: The Course Description XML
          1. Data exported as XML
          2. Modeling the structure for the import XML
      2. Topical Content: The Handbook XML
          1. Evaluating the handbook text for structure
          2. Modeling the structure as a set of topics
        1. Iteration and refinement
        2. Net results: vast improvements in understanding and speed
    4. Importing XML
      1. Doing It Adobe's Way: The Placeholder Approach
        1. Model the XML you want
          1. Get some structure into InDesign
          2. Create placeholders for XML elements
          3. Creating test XML
        2. Importing XML into placeholders
          1. Adding style to the XML elements
          2. Mapping styles to tags
          3. Importing the "real" XML file
        3. An aside: the scary Map Styles to Tags dialog message
        4. Mingling non-XML and XML content in a text flow
      2. Doing It Your Way: Using the Options for Your Own Process
        1. Import XML using only Merge, no other import settings
          1. Using Append
        2. Linking to external XML files
          1. External updates on Open and using the Links palette
        3. Creating text flows for the imported XML
        4. The importance of "document order" for imported XML
          1. Rearranging XML elements in the structure pane
          2. Fixing up structure in the Story Editor
      3. Understanding InDesign's XML Import Options
        1. Using "Clone repeating text elements"
        2. Importing only elements that match structure
        3. Avoiding overwriting text labels in the placeholder elements
        4. Deleting nonmatching structure, text, and layout components
      4. Importing Images
        1. Inline image imports
    5. Tagging XML in InDesign
      1. The Case for Tagging Content: Why You Need XML
      2. Tagging for Import
      3. Tagging for Iterative XML Development
        1. Working without an initial DTD
    6. Exporting XML
      1. Marking Up (Tagging) Existing Content for XML Export
      2. The Special Case of InDesign Tables (Namespaced XML)
        1. Examining the table
      3. Tagging Images as XML in InDesign
        1. Image Options in the Export XML Dialog
    7. Validating XML in InDesign
        1. Why validate?
      1. How to Validate XML in InDesign
        1. Loading a DTD and getting the correct root element
      2. Authoring with a DTD
        1. Dealing with validation problems
        2. Occurrence and sequences of elements
        3. Validating outside of InDesign
        4. Duplicating structure to build XML
        5. Cleaning up imported XML content
      3. Fast and Light Credo: Develop Now, Validate Later
        1. Iterating the information structure and DTD
    8. What InDesign Cannot Do (or Do Well) with XML
      1. The 1:1 Import Conundrum
      2. Bad Characters
      3. Inscrutable Errors, Messages, and Crashes
        1. The Devilish DTD suggestions
        2. Exporting from the element with the included DTD will not be valid
        3. Don't make InDesign "think" too hard on import or export with XSL
    9. Advanced Topics: Transforming XML with XSL
      1. An Aside Regarding Scripting InDesign and XML Rules-based Publishing
      2. XSLT for Wrangling XML; XML Scripting for Automating XML Publishing
      3. XSL: Extracting Elements from a Source XML File for a New Use
      4. XSL: Getting the Elements to Sort Themselves
      5. XSL: Getting Rid of Elements You Don't Want
      6. Creating Wrappers for Repeating Chunks
      7. Making a Table from Element Structures
      8. Upcasting Versus Downcasting
      9. Upcasting from HTML to XML for InDesign Import
      10. Downcasting to HTML
      11. Generate a Link with XSLT (Not Automated)
      12. Adding Useful Attributes to XML
        1. A general formula for adding attributes
        2. Generating an id attribute for a div
        3. Use of the lang attribute for translations
        4. Creating an image href attribute
          1. Pathing to images
      13. A Word about Using Find/Change for XML Markup in CS3
    10. Summary
    11. Resources
      1. InDesign Resources
      2. XML Resources
      3. XSLT Resources
      4. Acknowledgements
    12. About the Author

Product information

  • Title: XML Publishing with InDesign CS2+
  • Author(s):
  • Release date: June 2007
  • Publisher(s): O'Reilly Media, Inc.
  • ISBN: 9780596557737