Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

how do I add a code snippet to all topics in project?

Explorer ,
Apr 05, 2012 Apr 05, 2012

I have some java code that I need to add within the header of every topic in my help project. Is there an easy way to do this instead of individually adding topic by topic?

934
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Apr 05, 2012 Apr 05, 2012

Hi,

What version of RH are you using? What do you mean by header? The section in HTML or just in the top of every topic?

Try a master page/template. You can create a header and add the code in there. Assign the master page to all topics et voila.

Greet,

Willam

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Apr 05, 2012 Apr 05, 2012

sorry, I should be more specific....I'm using Robohelp 9 and it's not a template change that I'm making (such as a logo I want to appear at the top corner of every page) but a piece of code (google analytics to be specific) that needs to be added to every page to be able to track usage. The code needs to go on every page in order to analyze it.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Apr 05, 2012 Apr 05, 2012

Hi,

This is something you probably only want to do in your ouput. The GA code must be placed directly in front of the </head> tag, so a simple find and replace will help. Just replace </head> with the google code + '</head>'.

Greet,

Willam

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Apr 09, 2012 Apr 09, 2012

that would make sense to only add to the output. Can I do a find and replace all to the output files within robohelp or is there a better tool for that purpose?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Apr 11, 2012 Apr 11, 2012
LATEST

We use a tool called PowerGREP 4 to manipulate the output files. That may help.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
RoboHelp Documentation
Download Adobe RoboHelp