Ignore:
Timestamp:
2018-11-15T13:20:21+13:00 (5 years ago)
Author:
kjdon
Message:

for paged documents, if we are looking at the top level document, expand the first section in case there is no content in the top level section. but don't scroll to this section, in case there is.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone3/web/interfaces/default/transform/pages/document.xsl

    r32569 r32603  
    434434                            var sectionID = gs.cgiParams.d;
    435435                            var callbackFunction = null;
    436                             if(sectionID.indexOf("\\.") == -1)
     436                            if(sectionID.indexOf(".") != -1)
    437437                            {
    438438                                callbackFunction = function()
     
    441441                                };
    442442                            }
    443                        
     443                            else {
     444                               callbackFunction = function()
     445                                {
     446                               
     447                                expandAndExecute(sectionID+".1", null, null, null);
     448                                };
     449                            }
    444450                            var docID = sectionID.replace(/([^.]*)\..*/, "$1");
    445451                            var url = gs.xsltParams.library_name + "?a=d&c=" + gs.cgiParams.c + "&excerptid=gs-document&dt=hierarchy&d=" + docID;
Note: See TracChangeset for help on using the changeset viewer.