I have an error in my script finding a file. The servlet error log says
2001-09-18 09:01:17 - path="" :jsp: init
2001-09-18 09:02:08 - path="" :LoginServlet: init
2001-09-18 09:03:45 - path="" :abcServlet: init
2001-09-18 09:03:52 - path="" :xyzServlet: init
2001-09-18 09:03:55 - path="" :Error: /usr/local/apache/sites/abc.spinweb.net/htdocs/xxx/courses\3M/Introduction/3m_intro.html (No such file or directory)
As you can see a "\" is loaded after "courses" where a "/" should be. the html is loaded exactly where it says with the exception of the backward slash. I can't find where it is being called from, but suspect it lays in the code below. Could anyone help me in this matter, or tell me where else I should look. Thanks.
private String getAUHtml (String path){
path = path.replace ('\\', '/');
String response;
response = "<html>\n" +
"<head>\n" +
"</head>\n" +
"<body>\n" +
"<script language=\"JavaScript\">\n" +
"document.location = \"/cmi/courses/" + path + "\"\n" +
//"win = window.open ('','displayWindow','menubar=yes,scrollbars=yes,status=yes,width=300,height=300');\n" +
//"window.onload = \"win.close();\"" +
"</script>\n" +
"</body>\n" +
"</html>\n";
return response;
2001-09-18 09:01:17 - path="" :jsp: init
2001-09-18 09:02:08 - path="" :LoginServlet: init
2001-09-18 09:03:45 - path="" :abcServlet: init
2001-09-18 09:03:52 - path="" :xyzServlet: init
2001-09-18 09:03:55 - path="" :Error: /usr/local/apache/sites/abc.spinweb.net/htdocs/xxx/courses\3M/Introduction/3m_intro.html (No such file or directory)
As you can see a "\" is loaded after "courses" where a "/" should be. the html is loaded exactly where it says with the exception of the backward slash. I can't find where it is being called from, but suspect it lays in the code below. Could anyone help me in this matter, or tell me where else I should look. Thanks.
private String getAUHtml (String path){
path = path.replace ('\\', '/');
String response;
response = "<html>\n" +
"<head>\n" +
"</head>\n" +
"<body>\n" +
"<script language=\"JavaScript\">\n" +
"document.location = \"/cmi/courses/" + path + "\"\n" +
//"win = window.open ('','displayWindow','menubar=yes,scrollbars=yes,status=yes,width=300,height=300');\n" +
//"window.onload = \"win.close();\"" +
"</script>\n" +
"</body>\n" +
"</html>\n";
return response;