From: <pee...@us...> - 2003-08-01 00:37:45
|
Update of /cvsroot/digir/java/org/calacademy/digir/presentation In directory sc8-pr-cvs1:/tmp/cvs-serv22625 Modified Files: PresentationServlet.java Log Message: unhardcoded localhost:10080 as server:port for XSL generation Index: PresentationServlet.java =================================================================== RCS file: /cvsroot/digir/java/org/calacademy/digir/presentation/PresentationServlet.java,v retrieving revision 1.24 retrieving revision 1.25 diff -C2 -d -r1.24 -r1.25 *** PresentationServlet.java 31 Jul 2003 13:42:38 -0000 1.24 --- PresentationServlet.java 1 Aug 2003 00:37:41 -0000 1.25 *************** *** 689,692 **** --- 689,695 ---- SearchRequest freq = (SearchRequest) session.getAttribute("originalReq"); + String server = request.getServerName() + ":" + + request.getServerPort(); + response.setHeader("Content-Disposition", "attachment; filename=" + "searchResults"); *************** *** 702,706 **** Source xmlSource = new StreamSource(new StringReader(result)); //FIXME: can we make this call some other way, unhardcode localhost? ! URLConnection uconn = new URL("http://localhost:10080/pres/PresentationServlet?action=genTabResponseXSL").openConnection(); uconn.setDoOutput(true); uconn.setDoInput(true); --- 705,710 ---- Source xmlSource = new StreamSource(new StringReader(result)); //FIXME: can we make this call some other way, unhardcode localhost? ! //URLConnection uconn = new URL("http://localhost:10080/pres/PresentationServlet?action=genTabResponseXSL").openConnection(); ! URLConnection uconn = new URL("http://" + server + "/pres/PresentationServlet?action=genTabResponseXSL").openConnection(); uconn.setDoOutput(true); uconn.setDoInput(true); *************** *** 1025,1028 **** --- 1029,1034 ---- session.setAttribute("originalReq", freq); + String server = request.getServerName() + ":" + + request.getServerPort(); //FIXME, peej start *************** *** 1032,1036 **** Source xmlSource = new StreamSource(new StringReader(result)); //FIXME: can we make this call some other way, unhardcode localhost? ! URLConnection uconn = new URL("http://localhost:10080/pres/PresentationServlet?action=genHTMLResponseXSL").openConnection(); uconn.setDoOutput(true); uconn.setDoInput(true); --- 1038,1043 ---- Source xmlSource = new StreamSource(new StringReader(result)); //FIXME: can we make this call some other way, unhardcode localhost? ! //URLConnection uconn = new URL("http://localhost:10080/pres/PresentationServlet?action=genHTMLResponseXSL").openConnection(); ! URLConnection uconn = new URL("http://" + server + "/pres/PresentationServlet?action=genHTMLResponseXSL").openConnection(); uconn.setDoOutput(true); uconn.setDoInput(true); |