Changeset 3469 for trunk/gsdl3
- Timestamp:
- 2002-10-16T09:31:28+13:00 (22 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gsdl3/src/java/org/greenstone/gsdl3/core/Receptionist.java
r3387 r3469 109 109 Document message_doc = converter_.getDOM(xml_in); 110 110 Element message = message_doc.getDocumentElement(); 111 112 NodeList requests = message.getElementsByTagName("request");113 if (request s.getLength()==0) {114 return GSHTML.errorPage("no request sin the message");111 // there should only be one request per message 112 Element request = (Element)GSXML.getChildByTagName(message, "request"); 113 if (request == null) { 114 return GSHTML.errorPage("no request in the message"); 115 115 } 116 116 117 // should only be one request 118 Element req = (Element)requests.item(0); 119 String type = req.getAttribute("type"); // returns "" if no att of this name 117 String type = request.getAttribute("type"); // returns "" if no att of this name 120 118 if (!type.equals("action")) { 121 119 return GSHTML.errorPage("wrong type in request - should be action"); 122 } 123 String info = req.getAttribute("info"); 124 String action = GSPath.getFirstLink(info);120 } 121 122 String action = request.getAttribute("action"); 125 123 if (action.equals("")) { 126 124 return GSHTML.errorPage(" no action specified"); … … 143 141 String page = a.process(message); 144 142 return page; 145 // just pass a string for now - better to pass the doc cos already146 // parsed it, but we want a string back147 //String page = mi.process(xml_in);148 149 // output the page150 //return page;151 143 } 152 144
Note:
See TracChangeset
for help on using the changeset viewer.