在servlet 中使用 request.getSession().getServletContext().getRealPath("upload/" ); 獲取不到 tomcat 服務器目錄

        今天恰好有個上傳文件的練習需要使用 request.getSession().getServletContext().getRealPath("upload/" ); 獲取上傳到服務器上的文件路徑 C:\\apache-tomcat-7.0.47\\webapps\\CommonhelloWorldServlet \\upload 的目錄,結果獲取到的是 D:\eclipseWor
相關文章
相關標籤/搜索