Highlighted

How to make a mini-toc in Publish to HTML Help?

Community Beginner ,
Sep 17, 2015

Copy link to clipboard

Copied

Using Publish to HTML Help, how do I get a mini-toc in topics? I tried using the default HTML template which is installed here:

C:\Program Files (x86)\Adobe\AdobeFrameMaker2015\fminit\Publisher\Template\Document\PageTemplate\HTMLTemplate.htm

and also parts of the one online from here:

http://help.adobe.com/en_US/framemaker/2015/using/index.html#t=using-framemaker-2015%2Ffrm_generatin...

To use the template, in the Publish pod, I select "Microsoft HTML Help", click the "Edit" (settings) then select "Use HTML Page Template", click the Import button to load the template file. I've been able to make some simple boiler plate stuff work, but the mini-toc just shows as dead text.

The documentation says I should be able to insert something like this in the template HTML:

<div data-type=”minitoc”>

   <p data-type=”minitoc-caption”>This section covers the following:</p>

   <p data-type=”minitoc-level1”><span data-type=”minitoc-selector”>’H2_Heading2’</span></p>

   <p data-type=”minitoc-level2”><span data-type=”minitoc-selector”>’H3_Heading3’</span></p>

   <p data-type=”minitoc-level3”><span data-type=”minitoc-selector”>’H4_Heading4’</span></p>

</div>

But this results in the literal text 'H2_heading2' appearing instead of a variable replacement, and the whole thing is static.

Do I need to do something in FM or in the Publish settings to get this to work too? Do I need to manually insert mini-toc(s) into my FM documents? I was hoping it would be automatically generated.

Has anybody got the mini-toc feature to work? I'm sorry to ask but I've found virtually no documentation on this.

Thanks.

Views

410

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

How to make a mini-toc in Publish to HTML Help?

Community Beginner ,
Sep 17, 2015

Copy link to clipboard

Copied

Using Publish to HTML Help, how do I get a mini-toc in topics? I tried using the default HTML template which is installed here:

C:\Program Files (x86)\Adobe\AdobeFrameMaker2015\fminit\Publisher\Template\Document\PageTemplate\HTMLTemplate.htm

and also parts of the one online from here:

http://help.adobe.com/en_US/framemaker/2015/using/index.html#t=using-framemaker-2015%2Ffrm_generatin...

To use the template, in the Publish pod, I select "Microsoft HTML Help", click the "Edit" (settings) then select "Use HTML Page Template", click the Import button to load the template file. I've been able to make some simple boiler plate stuff work, but the mini-toc just shows as dead text.

The documentation says I should be able to insert something like this in the template HTML:

<div data-type=”minitoc”>

   <p data-type=”minitoc-caption”>This section covers the following:</p>

   <p data-type=”minitoc-level1”><span data-type=”minitoc-selector”>’H2_Heading2’</span></p>

   <p data-type=”minitoc-level2”><span data-type=”minitoc-selector”>’H3_Heading3’</span></p>

   <p data-type=”minitoc-level3”><span data-type=”minitoc-selector”>’H4_Heading4’</span></p>

</div>

But this results in the literal text 'H2_heading2' appearing instead of a variable replacement, and the whole thing is static.

Do I need to do something in FM or in the Publish settings to get this to work too? Do I need to manually insert mini-toc(s) into my FM documents? I was hoping it would be automatically generated.

Has anybody got the mini-toc feature to work? I'm sorry to ask but I've found virtually no documentation on this.

Thanks.

Views

411

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Sep 17, 2015 0
Adobe Employee ,
Sep 18, 2015

Copy link to clipboard

Copied

To quickly experience mini-toc feature of FM publish feature, please do these steps:

  1. FM > Help > UserGuide > Open UserGuide.book
  2. Open Publish Pod (Esc p h) >> Edit Responsive HTML5
  3. Check ON "Use HTML Page Template" >> Select HTMLTemplate.htm ($FMHOME\fminit\Publisher\Template\Document\PageTemplate\HTMLTemplate.htm)
  4. Save & Close
  5. Publish Responsive HTML5

A mini-TOC gets created in the output:

minitoc.PNG

How does the mapping work in miniTOC w.r.t the Para Tags?

The para tags that we define in HTML Page Template at level1, level2 etc are scanned from the FM document and are brought at the desired level in selected output.

To show it diagramatically - I have taken a screenshot:

minitocConcept.PNG

The concept of keeping it in HTML is to provide flexibility in terms of styling & customizations via CSS.

To create a Page Template for your FM file from scratch you may follow the link: Adobe FrameMaker (2015 release)

I apologize that we haven't done our bit to make this feature simple . But suggestions are always welcome

Do let us know if this makes it easy for you to get started.

Amit

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Sep 18, 2015 0
Community Beginner ,
Sep 18, 2015

Copy link to clipboard

Copied

Thanks for helping to explain this feature. I appreciate it. Your screen shot was useful.

I opened the User Guide book and published to HTML5 and HTML Help using that HTMLTemplate.htm file, however no mini-TOC was created. Not sure why. I used my own simple test with some headings and it sort of worked, but were a couple of problems.

1) When I loaded a page in the HTML Help viewer, it gives a script error:

2015-09-18 16_20_33-Script Error.png

The line in question I think is this:

document.write("<p class=\\"pt_breadcrumbs\\" ><a href=\"Personal_Spaceship_Operations_Manual.htm\">Home</a> &gt; ....snipped...

I clicked YES to continue running the script. The breadcrumbs part is missing from the output (probably due to the script error).

2) Second problem is the mini-toc seems incorrect:

2015-09-18 16_19_19-Source Insight 4.0.png

In the image above, why are the items in the mini-toc at different levels? They look correct in the main TOC on the left.

3) In your sample (and my results) I noticed that the heading numbers run into the text. For example "2.1.1heading text". How can I fix this? Can I remove the auto-number?

4) What if my FM doc uses different named heading styles? I have a document that uses "Heading1", not "H1_Heading1". How do I modify the HTMLTemplate.htm file so the mini-toc heading styles are found?

5) Finally, I was hoping a mini-toc could be placed at any level I want, even if the sub-headings are not contained within the page. For example, in my example above, suppose each heading 3 is in its own topic page. I would like to have a mini-toc at heading 2 level with links to the sub-headings. I'm not sure if that is how the FM mini-toc feature is designed to work.

Sorry for the long post, but thanks for your helpful efforts.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Sep 18, 2015 0
AMAGARWA LATEST
Adobe Employee ,
Sep 21, 2015

Copy link to clipboard

Copied

Hi,

Glad it helped! Replies to your queries below:

  1. The errors could have been due to some inconsistencies with the settings file or due to some js errors. Would suggest you to try with a new settings file [FM >> Publish Pod >> New >> Save & Close]
  2. There seems to be some inconsistency with the main TOC and mini TOC as you mentioned. It needs to be evaluated with the help of your source file + page template. Please send/attach.
  3. For this you may try this: [FM >> Publish Pod >> Edit >> Style Mapping >> Para Styles >> (Select a style that comprises your TOC one by one) >> Autonumber >> Select Ignore ]
  4. You may change the HTMLTemplate.htm directly or create a copy of it and modify it accordingly. Please note that when you create a copy do copy the .css and other files.
  5. To achieve this, you might have to use another mini-TOC feature. [FM >> Special >> Table of Contents >> Create mini-TOC] Once this mini-TOC is created you would be able to point to the other links that are separate topics.

Amit

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Sep 21, 2015 0