Revision 360
Added by bojilova over 24 years ago
src/edu/ucsb/nceas/metacat/MetaCatServlet.java | ||
---|---|---|
85 | 85 |
private String xmlcatalogfile = null; |
86 | 86 |
private String saxparser = null; |
87 | 87 |
private String defaultdatapath = null; |
88 |
private String servletpath = null; |
|
89 |
private String htmlpath = null; |
|
88 | 90 |
// path to directory where data files |
89 | 91 |
// that can be downloaded will be stored |
90 | 92 |
private String executescript = null; |
... | ... | |
112 | 114 |
saxparser = util.getOption("saxparser"); |
113 | 115 |
defaultdatapath = util.getOption("defaultdatapath"); |
114 | 116 |
executescript = util.getOption("executescript"); |
117 |
servletpath = util.getOption("servletpath"); |
|
118 |
htmlpath = util.getOption("htmlpath"); |
|
115 | 119 |
|
116 | 120 |
try { |
117 | 121 |
// Open a pool of db connections |
... | ... | |
222 | 226 |
out.println("</success>"); |
223 | 227 |
return; |
224 | 228 |
} |
225 |
response.sendRedirect("/xmltodb/index.html");
|
|
229 |
response.sendRedirect(htmlpath + "/index.html");
|
|
226 | 230 |
// aware of session expiration on every request |
227 | 231 |
} else { |
228 | 232 |
HttpSession sess = request.getSession(true); |
... | ... | |
230 | 234 |
// session expired or has not been stored b/w user requests |
231 | 235 |
// redirect to default page for query only access |
232 | 236 |
|
233 |
// response.sendRedirect("/xmltodb/sexpire.html");
|
|
237 |
// response.sendRedirect(htmlpath + "/sexpire.html");
|
|
234 | 238 |
} |
235 | 239 |
} |
236 | 240 |
// End of Jivka added |
... | ... | |
328 | 332 |
return; |
329 | 333 |
} else { |
330 | 334 |
response.sendRedirect( |
331 |
response.encodeRedirectUrl("/berkley/index.html"));
|
|
335 |
response.encodeRedirectUrl(htmlpath + "/index.html"));
|
|
332 | 336 |
} |
333 | 337 |
} catch ( java.io.IOException ioe) { |
334 | 338 |
sess.disconnect(); |
... | ... | |
353 | 357 |
} else { |
354 | 358 |
response.sendRedirect( |
355 | 359 |
|
356 |
response.encodeRedirectUrl("/berkley/metacat.html"));
|
|
360 |
response.encodeRedirectUrl(htmlpath + "/metacat.html"));
|
|
357 | 361 |
} |
358 | 362 |
} catch ( java.io.IOException ioe) { |
359 | 363 |
sess.disconnect(); |
... | ... | |
928 | 932 |
|
929 | 933 |
/** |
930 | 934 |
* '$Log$ |
935 |
* 'Revision 1.69 2000/08/15 15:58:03 berkley |
|
936 |
* 'Added decodeMouseAction(Hashtable) to decode the mouse click action outside of handleGetOrPost to allow for easy modification of images in a different application. |
|
937 |
* ' |
|
931 | 938 |
* 'Revision 1.68 2000/08/14 21:28:54 berkley |
932 | 939 |
* 'Broke up handleQueryAction into handleQuery, handleSQuery, runQuery and transformDocument. handleQueryAction is now a base function which makes calls to each of these functions to create, run and transform a query from CGI parameters. |
933 | 940 |
* ' |
Also available in: Unified diff
Cleared hardcoded paths for the location of .html files and use
the new "htmlpath" property from metacat.properties file