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

Problems with frames

Explorer ,
Nov 02, 2009 Nov 02, 2009

Copy link to clipboard

Copied

I use RH 8 and create a WebHelp. I use a frameset which was created in RH in the project manager. This frameset is my start page. It separates the online help in two parts, the help page on the left and additional information on the right. All links know which frame should be used. That works fine.

Using the online help shows some problems:

1. Searching

I search for a word and klick on a result. The page opens. But my frameset will be destroyed. My links within the pages and in the TOC are no longer working - of course they miss their frame. How can I tell the search function to use one of my frames?

2. TOC-synchronization

The TOC will not be synchronized when viewing the help pages.

But once I used the search function and my frameset is destroyed it works fine. I tried it out with some links which I prepared for this.

Is there a solution?

Thanks

Danny

Views

1.1K

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

correct answers 1 Correct answer

LEGEND , Nov 02, 2009 Nov 02, 2009

Hi,

Both your problems make sense. A frameset is not a topic, just a page that loads different topics in different panes. When you search, RoboHelp opens the topic directly and bypasses the frame. The TOC is not synchronized, because the current topic, the frameset, is not changed. You only load a different topic in the frameset.

As for your TOC synchronization problem, I don't see an easy solution, other than abandoning your frameset. For your other problem, you may get it to work by changing t

...

Votes

Translate

Translate
LEGEND ,
Nov 02, 2009 Nov 02, 2009

Copy link to clipboard

Copied

Hi,

Both your problems make sense. A frameset is not a topic, just a page that loads different topics in different panes. When you search, RoboHelp opens the topic directly and bypasses the frame. The TOC is not synchronized, because the current topic, the frameset, is not changed. You only load a different topic in the frameset.

As for your TOC synchronization problem, I don't see an easy solution, other than abandoning your frameset. For your other problem, you may get it to work by changing the output files. The TOC, Index and Search use hyperlinks which you can customize in the output files. Modify the hyperlinks, such as the one in whfhost.js (search) on line 410. Add target="<name of the frame you want the page to load in>", such as

sLine+="<dt><nobr><a href='"+gaTI.sTopicURL+"' target='myframe'>"+_textToHtml(gaTI.sTopicTitle)+"</a></nobr></dt>";

The do this for the TOC and the Index. Note, that once the frame killed, the TOC, Index and Search will stop functioning.

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
Explorer ,
Nov 03, 2009 Nov 03, 2009

Copy link to clipboard

Copied

Thanks Willam, this solution works for the search problem. I can live with the TOC problem.

My frames are not killed because every topic uses them.

I only wonder if there is another solution with RH to create two columns one for the topic and one for additional information.

Regards

Danny

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 ,
Nov 03, 2009 Nov 03, 2009

Copy link to clipboard

Copied

Hi,

You may want to check out the Iframe. This basically lets you add a frame within a page, so you kind of embed another page. You can position them using a table or DIV elements.

If it's only about creating two columns and you don't need to load other pages, a simple table might suffice.

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 ,
Jul 07, 2010 Jul 07, 2010

Copy link to clipboard

Copied

William,

I'm having the same problem with the search feature.  I have 2 frames that I'm using but when I click on the searched item link it destroys my frame.  I have tried you solution and you reference a line 410 in the whfhost.js file.  I have gone to that line in notepad++ and at line 410 I have the following code.

else
    break ;
   mid = Math.floor((end -begin ) / 2) ;

I have tried doing a search within the file and I have been unable to find the sting to make it display in the target of my choosing.  I'm also using RH 8 but I'm using Webhelp Pro and not Webhelp because of the reporting feature that we get.  Any help would be greatly appreciated.

Thank You,

Ian

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
Explorer ,
Jul 07, 2010 Jul 07, 2010

Copy link to clipboard

Copied

Hi Ian,

the described solution works fine but don't look for a specific line in whfhost.js. Search for one or more lines where the link is built and add target="xyz".

In my whfhost.js for example I have to change 2 lines: 3169 and 3178.

Both lines contain: " HREF='" + a_strUrl + "'" + ">"

The rest of both lines is not important but this rest needs to remain as it is.

Replace " HREF='" + a_strUrl + "'" + ">"

by " HREF='" + a_strUrl + "'" + "target='xyz'>"

in both lines and save the file.

I hope this also works for you.

Regards

Danny

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 ,
Jul 08, 2010 Jul 08, 2010

Copy link to clipboard

Copied

Danny,

Thank you for the response, but it is still not working for me.  This is the block of code that I have between lines 3165 and 3188.  I have made the chnages and maybe I'm doing something wrong.  would you mind taking a look at my code and seeing if I'm placing everything in the correct places?  My Javascipt coding is a little rusty and I might be doing something wrong.

function writeResult( a_strUrl, a_strHighlight, a_strTitle, a_strFont, a_nIndex, a_sSummary )
{
var strOutput = "";
if(a_sSummary.length > 0)
{
  strOutput = "<TR>" +
    "<TD CLASS='fr_tc'><A CLASS='fr_tc'" +
    " HREF='" + a_strUrl + "'" + "target='Ashford_Main'>" + _textToHtml_nonbsp(a_strTitle) + "</A><div>" + _textToHtml_nonbsp(a_sSummary) + "</div><br></TD>" +
    "<TD CLASS='fr_tc'> </TD>" +
    "<TD CLASS='fr_tc' STYLE='text-align:center'>" + a_nIndex + "</TD>" +
   "</TR>";
}
else
{
  strOutput = "<TR>" +
    "<TD CLASS='fr_tc'><A CLASS='fr_tc' STYLE='font-weight:normal;'" +
    " HREF='" + a_strUrl + "'" + "target='Ashford_Main'>" + _textToHtml_nonbsp(a_strTitle) + "</A></TD>" +
    "<TD CLASS='fr_tc'> </TD>" +
    "<TD CLASS='fr_tc' STYLE='text-align:center'>" + a_nIndex + "</TD>" +
   "</TR>";
}

return strOutput;
}

I will let you know that I ave viewed the search html code and I've looked at what it is creating for code and it is setting a target of bsscright, which I would assume is the default target, but I'm unable to find that in the code anywhere.

Thanks you again for you help,

Ian

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
Explorer ,
Jul 08, 2010 Jul 08, 2010

Copy link to clipboard

Copied

LATEST

Ian,

this looks exactly like my code. It should  work.

Are you addressing the correct frame?

I searched for bsscright and found what you mean. But I only changed the two lines in whfhost.js.

Did you refresh the page in your browser before testing your changes? Or is it possible that you need to delete the cash first? I don't know, I only guess things now.

Regards

Danny

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