2 Replies Latest reply on Jun 2, 2006 7:53 AM by Pete Lees

    Auto-Insert External Text in Topics

    RoboFan Level 1
      What I'd like to do is assign every topic in our Help system a level number. E.g., Level 1, Level 2, and Level 3.

      Then, I'd like to define each level in one place so that I can just insert a level number in each topic and have the corresponding defintion automatically appear within the topic.

      E.g., I define "Level 3" as "This information in this topic is confidential. Do not share with anyone outside of Company, Inc." I would then be able to insert "Level 3" in all relevant topics and have the text "This information..." automatically appear in each of those topics. The primary benefit of this is that if I change the defintion of a level, I can do it in one place and have it take effect for all topics with that level.

      The functionality I'm describing here is similar to how images are inserted in topics - I'm just not sure how to do it for text. (Of course one option to achieve this desired functionality is to simply insert screen shots of each defintion, but let's see if we can avoid that.) I'm thinking it might be possible using conditional text, html code, or scripts, but don't want to spend too much time exploring those if someone can provide a quick answer or point me in the right direction.

      Thanks!
        • 1. Re: Auto-Insert External Text in Topics
          Peter Grainge Adobe Community Professional (Moderator)
          Welcome to the forum.

          There is a method described on my site but it is not perfect. However, the problems are described so you can decide whether or not it is of use. I am not aware of any other method.

          Click here.

          I assume popups would not work for you.

          • 2. Re: Auto-Insert External Text in Topics
            Pete Lees Level 2
            RoboFan,

            You can easily do this by storing the reusable text in a script file and attaching it to each topic in the help system. For example, you might create a script file called global.js and add the following to it:

            level1 = "Whatever you want to say for this level.";
            level2 = "Some text to write in for this level";
            level3 = "This information in this topic is confidential. Do not share with anyone outside of Company, Inc";

            Then you'd link it to your topic files and write in the required text as shown in the example below.

            This is essentially the procedure that Peter describes in the following page of his Web site:

            http://www.grainge.org/pages/authoring/customising/terminology_1.htm

            Notice that there are a few hoops you may need to jump through if using this method in a compiled HTML Help (.chm) file, as otherwise your users may get error messages when they print topics to which the script file is attached.

            Pete