Changeset 26320 for main/trunk


Ignore:
Timestamp:
2012-10-16T15:19:43+13:00 (12 years ago)
Author:
kjdon
Message:

if we can't find an xsl name, and we are page action, then use teh subaction as the xsl name. That way a user can create a new page for her collection just by adding xsl file xxx.xsl and linking via a=p&sa=xxx

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone3/src/java/org/greenstone/gsdl3/core/TransformingReceptionist.java

    r26169 r26320  
    997997            name = this.xslt_map.get(action);
    998998        }
    999 
     999        if (name== null) {
     1000          // so we can reandomly create any named page
     1001          if (action.equals("p") && !subaction.equals("")) {
     1002            // TODO: pages/ won't work for interface other than default!!
     1003            name="pages/"+subaction+".xsl";
     1004          }
     1005         
     1006        }
    10001007        Document finalDoc = GSXSLT.mergedXSLTDocumentCascade(name, (String) this.config_params.get(GSConstants.SITE_NAME), collection, (String) this.config_params.get(GSConstants.INTERFACE_NAME), base_interfaces, _debug);
    10011008        return finalDoc;
Note: See TracChangeset for help on using the changeset viewer.