jsÄÜÈ¡µÃjspÖеĶÔÏóÂð£¿
¾ßÌå¾ÍÊÇ ÎÒÏëÓÃjsÈ¡µÃsessionÖеĶÔÏóÊý¾Ý·ÅÈëjsÖзâÆðÀ´
²»ÖªµÀ Äܲ»ÄÜʵÏÖ Ï£Íû¸÷λ¸ßÊÖÖ¸µãһϣ¡£¡ ²»Éõ¸Ð¼¤£¡£¡
ͨ¹ýjspÊä³öµ½Ò³ÃæÉÏ£¬ÓÃÒ»¸öÒþ²ØÓò°ÑÖµ¸ø±£´æÆðÀ´²»¾ÍÐÐÁËÂð£¿
Äã¿ÉÒÔ¸øJSµÄ·½·¨´«Öµ~·
±ÈÈç
function sess(session){
alert(session);
};
ÕâÑù´«Öµ
sess('"+ <%=session.get()%>+"');
Èç¹ûÊÇ×Ö·û´®Ö®ÀàµÄ¿ÉÒÔ°¡ var s=" <%=session.getAttribute("name")%>"
ÕâÑùÓ¦¸ÃÊÇ¿ÉÒԵİɡ£
~~ ÎÒµÄÒâ˼ÊÇÈ¡¶ÔÏóÊýÖµ ²»¹ý ×Ô¼ºÏëÁ˺þà ¾õµÃºÃÏñ²»¿ÉÄÜ ²»ºÃÒâ˼ÀÍ·³¸öλÀ²£¡£¡
<%@ page language="java" import="java.util.*,com.model.User" pageEncoding="UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<script type="text/javascript">
function testSession(){
var username=document.getElementById("username").value;
var password=document.getElementById("password").value;
}
</script>
</head>
<body onload="testSession()">
<%
User user = (User)ses
Ïà¹ØÎÊ´ð£º
type Exception report
message
description The server encountered an internal error () that prevented it from fulfilling this request.
exception
org.apache.jas ......
×î½üÒ»¸öÏîÄ¿ÖÐÓöµ½Ò»¸öÎÊÌ⣺ÔÚÔÓеÄÒ»Ì×ϵͳÖÐ(php¿ª·¢)Ìí¼ÓһЩС¹¦ÄÜ(jsp¿ª·¢)£¬ÔÀ´Óû§ÏµÍ³¶¼ÊÇphp¿ª·¢µÄ£¬ÎÒÈçºÎÔÚjsp¿ª·¢µÄ¹¦ÄÜÖÐ×öµ½Óû§ÐÅÏ¢sessionͬ²½ÄØ£¿ ÓÐÈËÊÇ·ñÓÐ×ö¹ýÀàÒÔÏîÄ¿£¬ÏëÌýÌý´ó¼ÒµÄ¿´·¨
......
±ÈÈç˵DB.classÊÇÔÚ°ücom/zhl/jdbcϵÄ
ÄÇôDB.class·ÅÔÚʲôµØ·½ Èç¹ûÓÃ<jsp:useBean id="d" class=""/>À´ÒýÈëbean ÄÇôclassÊôÐÔÓ¦¸ÃÔõôд
Ðè²»ÐèÒªÏñservletÄÇÑù»¹ÒªÅäÖÃweb.xmlµÄ& ......
ÎÊÌâ: ÏÖÔÚÌá½»Ö®ºó¾Í²»ÄÜÌøµ½ajax.jsÖÐÖ¸¶¨µÄservlet
¶øÊÇÓÖÖØÐ½øÈëµ½ÁËpub_hotel_t.jspÒ³Ãæ. Ò²¾ÍÊÇûÓÐÖ´Ðе½ajaxÀïÃæÈ¥ ´ó¼Ò°ïæ¿´¿´ÊÇʲôÔÒò°É.
ÊDz»ÊǺÍÌá½»µÄ°´Å¦ÓйØÄ ......
ÎÒµÄ˼·ÊÇ ÉÏ´«£¨ÎļþÑ¡Ôñ¿ò£©-> ͨ¹ý·¾¶¶ÁÈ¡Îļþ£¬×ª³É¶þ½øÖÆÁ÷¶ÁÈëÊý¾Ý¿â ->Êý¾Ý¿â»ñÈ¡¶þ½øÖÆÁ÷£¬±£´æÎª.pdf ->ÏÔʾ
ÏÖÔÚǰÈý²½¶¼ÊÇʵÏÖÁË£¬±£´æµÄPDF¹Ì¶¨Â·¾¶ÒÔ¼°Ãû³Æ£¨·ÅÔÚWebRootĿ¼Ï£¬out.pdf£© ......