如何调用文件到jsp? [英] how to call file in to jsp?

查看:92
本文介绍了如何调用文件到jsp?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这是我的JSP页面。

This my JSP page.

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
        pageEncoding="ISO-8859-1" %>


    <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

    <html>

    <head>

    <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">

    <title>Insert title here</title>

    </head>

    <body>

    <jsp:useBean id="link" class="com.Sshexample">

    <%= link.callconst()%>

    </jsp:useBean>

    </body>

    </html>

我想问这是我正在调用.java文件的ma页面。 unix server.can任何正文告诉我为什么会收到此错误?

i want to ask this is ma page that i musing to call .java file which is making connection with unix server.can any body tell me why i am getting this error?

org.apache.jasper.JasperException: org.apache.jasper.JasperException: Unable to load class for JSP
    org.apache.jasper.servlet.JspServletWrapper.getServlet(JspServletWrapper.java:156)

    org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:329)

    org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:313)

    org.apache.jasper.servlet.JspServlet.service(JspServlet.java:260)

    javax.servlet.http.HttpServlet.service(HttpServlet.java:717)

我正面临这个问题................?

i am facing this problem................?

推荐答案

< jsp:useBean> 内写了<%= link.callconst()% >

<body>

    <jsp:useBean id="link" class="com.Sshexample">

    <%= link.callconst()%>

    </jsp:useBean>

    </body>

使用此

<body>

    <jsp:useBean id="link" class="com.Sshexample"></jsp:useBean>

     <%= link.callconst()%>
    </body>

这篇关于如何调用文件到jsp?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆