Changeset 26499


Ignore:
Timestamp:
2012-11-22T14:31:44+13:00 (9 years ago)
Author:
sjm84
Message:

The debug behaviour is triggered via the debug cgi argument instead of requiring a recompile

Location:
main/trunk/greenstone3/src/java/org/greenstone/gsdl3
Files:
2 edited

Legend:

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

    r26473 r26499  
    6464    protected HashMap<String, ArrayList<String>> _metadataRequiredMap = new HashMap<String, ArrayList<String>>();
    6565
    66     boolean _debug = false;
     66    boolean _debug = true;
    6767
    6868    public TransformingReceptionist()
     
    496496    protected Node transformPage(Element page)
    497497    {
     498        _debug = false;
     499
    498500        boolean allowsClientXSLT = (Boolean) config_params.get(GSConstants.ALLOW_CLIENT_SIDE_XSLT);
    499501        //System.out.println("Client side transforms allowed? " + allowsClientXSLT);
     
    644646
    645647            inlineTemplate = (String) params.get(GSParams.INLINE_TEMPLATE);
     648
     649            if (params.get(GSParams.DEBUG) != null && (((String) params.get(GSParams.DEBUG)).equals("on") || ((String) params.get(GSParams.DEBUG)).equals("1")))
     650            {
     651                _debug = true;
     652            }
    646653        }
    647654
  • main/trunk/greenstone3/src/java/org/greenstone/gsdl3/util/GSParams.java

    r26445 r26499  
    8181    public static final String EXTERNAL_LINK_TYPE_DIRECT = "direct";
    8282    public static final String EXTERNAL_LINK_TYPE_FRAMED = "frame";
     83   
     84    public static final String DEBUG = "debug";
    8385
    8486    protected HashMap<String, Param> param_map = null;
     
    127129        addParameter(EXCERPT_ID, false);
    128130        addParameter(EXCERPT_TAG, false);
     131       
     132        addParameter(DEBUG, false);
    129133    }
    130134
Note: See TracChangeset for help on using the changeset viewer.