Yes, I've looked at that issue. I have not encountered it in my own books
yet.
This current one though is a webhelp showstopper for anyone who is not
chunking every section. Not having all of the anchors working from the
table of contents defeats most of the purpose of this output format.
Nat
On Tue, Mar 25, 2014 at 6:14 PM, Kasun Gajasinghe <
kasunbg@gmail.com> wrote:
> The above code is kind of a hack to workaround an issue. The reason is
> explained in the source itself that you have pointed. We need to think what
> would be the proper approach to fix rather than having a workaround. The
> current alternative we have has some drawbacks. I guess I provided you the
> link to it previously.
>
>
> On Tue, Mar 25, 2014 at 10:31 AM, natk <
nkershaw@gmail.com> wrote:
>
>> I think I have the source of this problem, which is the following code in
>> main.js (also the source of another problem I was having):
>>
>> // When you click on a link to an anchor, scroll down
>> // 105 px to cope with the fact that the banner
>> // hides the top 95px or so of the page.
>> // This code deals with the problem when
>> // you click on a link within a page.
>> $('a[href*=#]').click(function() {
>> if (location.pathname.replace(/^\//,'') == this.pathname.replace(/^\//,'')
>> && location.hostname == this.hostname) {
>> var $target = $(this.hash);
>> $target = $target.length && $target
>> || $('[name=' + this.hash.slice(1) +']');
>> if (!(this.hash == "#searchDiv" || this.hash == "#treeDiv" || this.hash
>> == "") && $target.length) {
>> var targetOffset = $target.offset().top - 120;
>> $('html,body')
>> .animate({scrollTop: targetOffset}, 200);
>> return false;
>> }
>> }
>> });
>>
>> When I comment out this code, I can click on the anchors successfully.
>>
>> Any chance of this getting fixed sometime soon?
>>
>> Nat
>>
>>
>> On Tue, Mar 25, 2014 at 2:22 PM, natk <
nkershaw@gmail.com> wrote:
>>
>>> I am having trouble navigating using the webhelp navigation panel when I
>>> click on a local anchor.
>>>
>>> I have the chunk.section.depth parameter set to 1.
>>>
>>> The following docbook sample demonstrates the problem:
>>>
>>>
>>> <book id="Test" xmlns="http://docbook.org/ns/docbook" version="5.0">
>>>
>>> <chapter>
>>>
>>> <para>Text of section 1.1</para>
>>>
>>> <para>Text of section 1.1.2</para>
>>>
>>>
>>> <para>Text of section 1.1.2</para>
>>>
>>> >>> </chapter>
>>> <chapter></chapter>
>>> </book>
>>>
>>> Once I have browsed to the file which contains the Section 1.1 (see
>>> attached ch01s01.html), I cannot browse to Section 1.1.1 or Section 1.2.2,
>>> which are local to that file. The HTML looks fine, so I am guessing this is
>>> a javascript issue.
>>>
>>> Nat
>>>
>>
>>
>
>
> --
> ~~~*******'''''''''''''*******~~~
> *Kasun Gajasinghe*
> Software Engineer; WSO2 Inc.;
http://wso2.com,> *linked-in: *http://lk.linkedin.com/in/gajasinghe
> *blog: **http://blog.kasunbg.org* <http://blog.kasunbg.org/>
>
>
> *twitter: **http://twitter.com/kasunbg* <http://twitter.com/kasunbg>
>