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

Using a variable to insert into a URL for redirecting clients

New Here ,
Jun 25, 2012 Jun 25, 2012

Copy link to clipboard

Copied

I got a good one, can anyone help on this?

Using RoboHelp Version 8.02.208.

My company uses MicroStrategy to deploy several web-based data analysis products.

Each of these data products (there are 5) are deployed on different servers.

I have set up a single source WebHelp project and use build tags for product specific help output.

(I also have to modify the Start Page, TOC and Default Topic settings prior to generating each product help)

Everything on this works fine and is not a problem.

We have just implemented an Excel add-in for one of the products.

That add-in uses a locally installed CHM file for its help.

In order to provide customized help that can be updated without forcing the clients to reinstall the CHM help file locally, the source for the CHM file has one dummy topic. In that topic, I have used HTML code to redirect the client to the WebHelp for the product and have integrated the Excel add-in help to that product’s customized help. The result is that the CHM file is opened locally in the HTML help viewer. Inside the HTML help viewer window, I open the WebHelp.

The redirect HARD CODES the URL with the product specific server name and Start Page help topic.

That works fine and is not a problem for ONE PRODUCT.

We are in the process of adding this Excel add-in to other products.

Now here is where I cannot get this to work with my implementation.

The URL for each product is different and to make matters worse, the Start Page is different for each product as well.

So, I am working on options for implementation of multiple products and here is my question:

(1)    The following is an example of the redirect in the single topic of the CHM file:

<meta http-equiv="refresh" content="0;URL=https://server.com/ProductName/WebHelp/StartPage.htm#mergedProjects/ExcelPlugIn/ Overview.htm" />

(2)    The red portion of the URL above will need to be modified to support each individual product with a custom server, product name and start page HTM file name.

Is there a way to:

(1)    Add a variable in this HTML code

(2)    Once the product is identified, update the variable with the product specific URL content

(3)    Integrate the variable into the target URL of the HTML code that does the redirect

I think this is either not possible or more work than needed. My other option is to provide standalone Excel add-in help on a server and just have the Excel plug-in go to that (right now it is integrated into the product specific help and the client has access to the plug-in help AND the application help all at the same place).

Thanks to all in advance for any help/suggestions.

Michael F Weart

mweart@corelogic.com

Views

1.6K

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
community guidelines
LEGEND ,
Jun 25, 2012 Jun 25, 2012

Copy link to clipboard

Copied

Hi Michael

Instead of amending the URL, why not have a different redirect page for each product and control the page that is included by applying a build tag to the topic?

Just thinking out loud here... Rick

Helpful and Handy Links

RoboHelp Wish Form/Bug Reporting Form

Begin learning RoboHelp HTML 7, 8 or 9 within the day!

Adobe Certified RoboHelp HTML Training

SorcerStone Blog

RoboHelp eBooks

Votes

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
community guidelines
LEGEND ,
Jun 25, 2012 Jun 25, 2012

Copy link to clipboard

Copied

Rick's solution is simple and elegant. I couldn't resist pointing out the hard way anyway.

The hard way would be to conditionalize the redirect using JavaScript. You somehow save the correct parameter on the page (for example with a variable) and you use a script to read that value. The script can then redirect to the desired URL. I would go this way because you only need a single page, but this is not the easy, straightforward way.

Greet,

Willam

Votes

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
community guidelines
New Here ,
Jun 26, 2012 Jun 26, 2012

Copy link to clipboard

Copied

Thanks for the feedback - here is more informtion on the challenges of this implementation:

I can only distribute one CHM file to cover all 5 web-based products that can be accessed through the Excel plug-in.

Regardless of which of our 5 products is used to install the plug-in on the client's local hard drive, the same installer is used.

That one CHM file is installed locally on the client's hard drive.

(The out of the box CHM file for the plug-in only has general plug-in help content the locl install causes problems for updating the content).

We needed to be able to easily update the help without inconveniencing the clients.

So, I am not creating 5 different CHM files for each installer, since there is only one installer regardless of how many of the 5 products they have.

The plug-in has a server setting and web service setting for each product and the client must choose which they are accessing when they fire up the plug-in.

They may be accessing the plug-in for any of our 5 web-based products they have subscriptions for.

Which means, the one CHM file must be able to:

(1) determine the product they are accessing

(2) direct to one of the 5 servers with the online help.

Each of the 5 online helps are deployed on separate servers with different URL links (and the helps have all different URL links as well).

These online webhelp outputs have some identical content but also some customized content for the specific product they are actually accessing.

My original approach was pretty much the same as William's above. Have a variable in the CHM help, determine the server they are accessing from the plug-in and insert the customized portion of the URL to access the appropriate webhelp.

Keep the ideas/suggestions coming.

I also have a development person looking into how to update a variable on the CHM side to populate the URL.

Michael F Weart

mweart@corelogic.com

Votes

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
community guidelines
New Here ,
Jun 26, 2012 Jun 26, 2012

Copy link to clipboard

Copied

LATEST

Another path I am researching, Map IDs.

Create a Microsoft HTML help project with 5 topics - one topic for each of the MicroStrategy data applications.

Each topic is assigned a map ID - from 1 through 5.

Each topic redirects the client to the application specific help (and the Excel Plug-In help is merged into it).

On the call to the CHM file from the Excel add-in, include the MapID based on the MSTR application it is linked to.

Example for call to hh.exe (example uses Map ID 2):

hh.exe -mapid 2 "C:\Program Files (x86)\MicroStrategy\Office\moimain.chm

The only problem here is if the development team cannot customize the call to the CHM help file.

I have also tried a javascript implementation and have gotten progress, I just have to get a parameter and parse it out and feed it to the javascript.

Keep the suggestions coming as I may run into roadblocks on the options I am trying now.


Thanks to all --

MFW

Votes

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
community guidelines
Resources
RoboHelp Documentation
Download Adobe RoboHelp