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

JavaScript - Inserting globally

Guest
May 23, 2008 May 23, 2008
Hi Everyone,
I am using RH6 and outputting FlashHelp.
Is there a way to insert a javascript into ALL of your topics? Or is it only possible to insert a script into one topic at a time?
Also, The script I need to insert has two parts...one part has to go into the HEAD tag and the other part has to go into the BODY tag.
Why am I asking? Because we are going to start using a web analytics product to analyze hit counts in the Help. We did not buy RoboServer and don't want to. (Our web servers are Apache and RoboServer doesn't run on that.)
Anyhow, the web analytics product that we are using requires me to insert a javascript into each HTML file.
Thanks all,
Joe
340
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 ,
May 23, 2008 May 23, 2008
Hi Joe.

You can only add a javascript to one topic at a time inside RH but if you use a find and replace tool you can do it across multiple files. FAR and BkReplacem are two popular ones. Just Google them.
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 ,
May 23, 2008 May 23, 2008
Just a further thought, add the javascript to template and then all new topics should automatically contain it. I haven't tested this but it would save having to repeat the process for future releases.
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
Enthusiast ,
May 23, 2008 May 23, 2008
LATEST
Hi, Joe,

You should be able to store your scripts in one or more external JavaScript (.js) files, which you then reference in the Head or Body section of your topics. See this page for more information:

http://www.w3schools.com/js/js_whereto.asp

Pete
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