10 Replies Latest reply on Dec 22, 2008 11:17 AM by Peter Grainge

    .hhk upload problem

    bluepoetgirl
      When I generate htmlhelp from dita, I open the .hhp in RoboHelp to generate WebHelp. Doing so changes the .hhk file so that any indexterm that references more than one topic is only referenceing the first topic listed under the object.

      I need to be able to have the same index term reference various topics. Is there anyway this is possible, other than doing a find and replace in the .hhk to format it like the whidata0.xml and then saving it as whidata0.xml?
        • 1. Re: .hhk upload problem
          Peter Grainge Adobe Community Professional (Moderator)
          Welcome to the forum.

          Not sure we allow blue poetry!

          I'm not sure why the index is working that way but my first curiosity is why you are opening the project from the HHP file rather than the XPJ.

          What you want is the normal way an index works. Was it created in RH?

          • 2. Re: .hhk upload problem
            bluepoetgirl Level 1
            My files are in dita. So I use ant to process these files through the dita open toolkit. It produces html for every file and also produces the .hhp, .hhk, and .hhc. I open the .hhp in RoboHelp to generate WebHelp.
            • 3. Re: .hhk upload problem
              bluepoetgirl Level 1
              There is no xpj until after I open the hhp with RoboHelp
              • 4. Re: .hhk upload problem
                Peter Grainge Adobe Community Professional (Moderator)
                Now I see the DITA relevance.

                Are you saying that if the keyword is Animals, that only Cat appears in the WebHelp or the Cat and Dog appear but when you click Dog, it goes to the Cat topic?

                If you look at the index in the RH editor, what does that show under Animals?

                • 5. Re: .hhk upload problem
                  bluepoetgirl Level 1
                  the hhk would originally say this:

                  <ul>
                  <li> <object type="text/sitemap">
                  <param name="Name" value="Animals">
                  <param name="Name" value="Cats">
                  <param name="Local" value="Cats.html#Cats">
                  <param name="Name" value="Dogs">
                  <param name="Local" value="Dogs.html#Dogs">
                  </object>

                  When the hhp is opened in RoboHelp the hhk is changed to say:

                  <ul>
                  <li> <object type="text/sitemap">
                  <param name="Name" value="Animals">
                  <param name="Name" value="Cats">
                  <param name="Local" value="Cats.html#Cats">
                  </object>

                  When WebHelp is generated the whidata0.xml looks like this:

                  <indexdata>
                  <key name="Animals" >
                  <topic name="Animals" url="Cats.html#Cats" />

                  For it to work how I want it to the whidata0.xml should look like this:

                  <indexdata>
                  <key name="Animals" >
                  <topic name="Cats" url="Cats.html#Cats" />
                  <topic name="Dogs" url="Dogs.html#Dogs" />

                  I hope this clears everything up. How it works now...only one topic can be linked to each index term.

                  Thanks,
                  Sarah
                  • 6. Re: .hhk upload problem
                    Peter Grainge Adobe Community Professional (Moderator)
                    Create a new project in RH with a topic titled Animals and create an index in RH with both index words.

                    How does that compare with the index your tools are creating.

                    Your project is not on a network is it? If it is, move it locally as RH will not work properly across a network.

                    • 7. Re: .hhk upload problem
                      bluepoetgirl Level 1
                      In the new project I created in RoboHelp, the index has a keyword called Animals. When I click Animals, it displays a drop-down that says:

                      Cats
                      Dogs

                      Both will take you to the correct topics they are related to.

                      In the project I generate with DITA, if you click on Animals in the index, it takes you to the Cats topic. Dogs is not an option.
                      • 8. Re: .hhk upload problem
                        Peter Grainge Adobe Community Professional (Moderator)
                        OK so you have established an index generated in RH works as desired. It should now be a case of examing that HHK file in a text editor and the one you are getting from your process. There has to be a difference.

                        • 9. Re: .hhk upload problem
                          bluepoetgirl Level 1
                          So the code generated by the toolkit in the .hhk file looked like this:

                          <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
                          <html>
                          <head>
                          <meta name="GENERATOR" content="Microsoft&reg; HTML Help Workshop 4.1">
                          <!-- Sitemap 1.0 -->
                          </head>
                          <body>
                          <ul>
                          <li> <object type="text/sitemap">
                          <param name="Name" value="Animals">
                          <param name="Name" value="Cats">
                          <param name="Local" value="Cats.html#Cats">
                          <param name="Name" value="Dogs">
                          <param name="Local" value="Dogs.html#Dogs">
                          </object>
                          </li>
                          </ul>
                          </body>
                          </html>

                          The code in the .hhk file created by the new RoboHelp project, that works, looks like this:

                          <html>
                          <!-- Sitemap 1.0 -->
                          <object type="text/site properties">
                          <param name="SiteType" value="index">
                          </object>
                          <ul>
                          <li><object type="text/sitemap">
                          <param name="Name" value="Animals">
                          <param name="Name" value="Cats">
                          <param name="Local" value="Cats.htm">
                          <param name="Name" value="Dogs">
                          <param name="Local" value="Dogs.htm">
                          </object>
                          </ul>
                          </html>


                          How to fix the problem:

                          Copy and paste the following code into the .hhk generated by the toolkit, before you open the ,hhp in RoboHelp:

                          <object type="text/site properties">
                          <param name="SiteType" value="index">
                          </object>

                          That .hhk now looks like this:

                          <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
                          <html>
                          <head>
                          <meta name="GENERATOR" content="Microsoft&reg; HTML Help Workshop 4.1">
                          <!-- Sitemap 1.0 -->
                          </head>
                          <body>
                          <object type="text/site properties">
                          <param name="SiteType" value="index">
                          </object>
                          <ul>
                          <li> <object type="text/sitemap">
                          <param name="Name" value="Animals">
                          <param name="Name" value="Cats">
                          <param name="Local" value="Cats.html#Cats">
                          <param name="Name" value="Dogs">
                          <param name="Local" value="Dogs.html#Dogs">
                          </object>
                          </li>
                          </ul>
                          </body>
                          </html>

                          Now the index works just fine.
                          • 10. Re: .hhk upload problem
                            Peter Grainge Adobe Community Professional (Moderator)
                            Glad it was that easy in the end.