当前位置: 动力学知识库 > 问答 > 编程问答 >

filenotfoundexception - HTTP Status 500 file not found error in jsp include

问题描述:

I include file from my root directory. Its working fine in local but when I host my site its give me:

error HTTP Status 500: "../connection.jsp" not found

My files are in

public_html/myfolder/connection.jsp

on shared hosting.

I want to include file in

public_html/myfolder/process/user-login.jsp

网友答案:

If public_html is a root folder of your web application, then you can use absolute path to the included resource.

<jsp:include page="${pageContext.request.contextPath}/myfolder/connection.jsp"/>
分享给朋友:
您可能感兴趣的文章:
随机阅读: