Loading ...
Sorry, an error occurred while loading the content.

Re: Need Xref to PDF and html

Expand Messages
  • virginiakelleycomcastnet
    Anyone? The DITAC samples fail also. Local links to topics in the same doc in the DITA docs also fail. Disappointing...do you mean to say this thing can only
    Message 1 of 6 , Apr 27 10:01 AM
    View Source
    • 0 Attachment
      Anyone?


      The DITAC samples fail also. Local links to topics in the same doc in the DITA docs also fail. Disappointing...do you mean to say this thing can only do a hard coded ...

      HTTP://www.myurl.com/mytopic?

      That's the crappiest thing I've ever heard. What did I miss?
    • Eliot Kimber
      The value of @href must be a URI, that is a URL or URN. Your example is using a Windows file path, which should never work but some tools may incorrectly
      Message 2 of 6 , Apr 28 5:41 AM
      View Source
      • 0 Attachment
        The value of @href must be a URI, that is a URL or URN. Your example is
        using a Windows file path, which should never work but some tools may
        incorrectly resolve it.

        Note that the processing of book-to-book cross references is a bit fuzzy in
        DITA 1.2, as the details of the rendered result depend on many variables,
        including where the document you're publishing will be served in relation to
        the document you're liking to.

        It may be necessary for your local publishing tools to know what the right
        thing to do is, which may require customization.

        However, you have, except for the URL details, created the correct markup
        for a cross-book link between two closely-related publications.

        @scope of "peer" means that the two publications are probably processed
        together or from the same source and probably delivered by the same service.

        @scope of "external" means that the document making the reference has no
        source or delivery relationship to the target, which usually needs to be
        referenced by an absolute URL, usually to the delivered form, not the source
        format.

        Note also that for a reference to a DITA map, the fragment identifier is
        unnecessary because you are pointing to the entire map document and naming
        the containing file means "I'm pointing to the root element of this
        document" per DITA-defined addressing rules.

        One potential ambiguity in this situation is what *rendered* form you want
        the rendered reference to point to. An obvious rule is "like to like" but
        that's not the only possible rule. For example, from HTML you might want to
        create references to the HTML and PDF versions.

        Your choice in that case is to either do something custom in your processing
        system to give authors a way to signal their intent or to author references
        to the rendered forms, not the source forms.

        I don't normally recommend the latter approach because it makes your source
        inflexible but it may be the most direct pragmatic solution.

        Ways to signal intent include:

        - Using @outputclass to indicate the desired rendered form.
        - Using a query parameter as part of the URL, e.g.
        ".../Somedoc.ditamap?targetForm=pdf"
        - A runtime flag that applies to all references of a certain scope or within
        a certain directory or whatever.

        For DITA 1.3 we are discussing ways to make cross-publication addressing
        more explicit and controllable but we haven't yet finalized our approache.
        But it will likely hinge on the use of keys and the generation of
        intermediate key definitions that serve to bind references as authored to
        the appropriate targets as rendered for a specific processing instance.

        For example, for a set of potential targets you might generate a set of key
        definitions that provide both the HTML and PDF locations of those targets
        *as rendered* and then use those generated keys when processing your
        referencing document.

        Finally, the DITA for Publishers project provides an attribute domain,
        d4pRenditionTarget, that provides a conditional attribute specifically for
        selecting on the rendition target, e.g., HTML or PDF or whatever. You can
        use that attribute to have different forms of the same xref to reflect
        different rendered versions. Not the ideal solution, because it requires
        either redundant xrefs in the source or multiple rendition-type-specific
        keys, but it does serve as a pragmatic solution to controlling
        rendition-specific details of publications.

        Cheers,

        Eliot

        On 4/16/12 12:45 PM, "virginiakelleycomcastnet"
        <virginia.kelley@...> wrote:

        > Helllppppp! How do I get xrefs to work for PDF and html outputs for:
        >
        > *Windows
        > *DITAC 2.1
        > *XMLMind 4.6 --->Do I set some flag for each type of compile?
        >
        > PDF- Works. Links to topic in another ditamap
        >
        > <li><xref href="..\folder\xfile.xml#xfile" type="DITA" format="ditamap"
        > scope="peer">zzzzzzzzzz</xref>
        >
        > HTML - Fails. No link at all.
        >
        >
        >
        >

        --
        Eliot Kimber
        Senior Solutions Architect, RSI Content Solutions
        "Bringing Strategy, Content, and Technology Together"
        Main: 512.554.9368
        www.rsicms.com
        www.rsuitecms.com
        Book: DITA For Practitioners, from XML Press,
        http://xmlpress.net/publications/dita/practitioners-1/
      • virginia.kelley@comcast.net
        Thank you Eliot. Would you have an example of how to use d4pRenditionTarget to direct the output to PDF or WebHelp? -V
        Message 3 of 6 , May 3, 2012
        View Source
        • 0 Attachment

          Thank you Eliot.

           

          Would you have an example of how to use

          d4pRenditionTarget to direct the output to PDF or WebHelp?

           

           

          -V

           

           

        • Eliot Kimber
          You would need to integrate the vocabulary domain into your local document type shells. The shells included with the DITA for Publishers materials demonstrate
          Message 4 of 6 , May 3, 2012
          View Source
          • 0 Attachment
            You would need to integrate the vocabulary domain into your local document
            type shells. The shells included with the DITA for Publishers materials
            demonstrate how to do the integration.

            However, you can also use @props directly to get the same effect without the
            need for the new attribute, e.g.:

            <keydef props="(d4p_renditionTarget epub)" ...>

            And then in your DITAVAL you would configure the d4p_renditionTarget
            condition just as you would any other.

            Note that there was a bug in earlier Toolkits where filtering was not
            applied to maps correctly for specialized selection atts. That bug is
            definitely fixed in the 1.6 version of the Toolkit and may have been fixed
            in the latest 1.5 version, not sure.

            Cheers,

            Eliot

            On 5/3/12 11:50 AM, "virginia.kelley@..."
            <virginia.kelley@...> wrote:

            > Thank you Eliot.
            >
            >
            >
            > Would you have an example of how to use
            >
            > d4pRenditionTarget to direct the output to PDF or WebHelp?

            --
            Eliot Kimber
            Senior Solutions Architect, RSI Content Solutions
            "Bringing Strategy, Content, and Technology Together"
            Main: 512.554.9368
            www.rsicms.com
            www.rsuitecms.com
            Book: DITA For Practitioners, from XML Press,
            http://xmlpress.net/publications/dita/practitioners-1/
          • virginia.kelley@comcast.net
            For others trying this same basic set of functionality.... WORKS on Web Help while running on a TomCat Server FAILS IN PDF tries to an external load a file
            Message 5 of 6 , May 3, 2012
            View Source
            • 0 Attachment

              For others trying this same basic set of functionality....

               

               

              WORKS on Web Help while running on a TomCat Server
              FAILS IN PDF tries to an external load a file (does not seek the bookmark)
              <xref  href="myFileinAnotherMap"
              type="DITA" format="ditamap" scope="peer">
              zzzzzzzzzz</xref>

              Where myFileinAnotherMap is an .XSL Dita file that is also in the same build


              From: "virginia kelley" <virginia.kelley@...>
              To: dita-users@yahoogroups.com
              Sent: Thursday, May 3, 2012 9:50:47 AM
              Subject: Re: Need Xref to PDF and html

              Thank you Eliot.

               

              Would you have an example of how to use

              d4pRenditionTarget to direct the output to PDF or WebHelp?

               

               

              -V

               

               

            Your message has been successfully submitted and would be delivered to recipients shortly.