Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

ÔõôÓÃajax·µ»ØÊý¾Ý - Web ¿ª·¢ / Ajax

jspÒ³Ã棺

<s:select list="deptMap" name="deptid" listKey="key" value="%{deptid}" listValue="value" headerKey="" headerValue="--ÇëÑ¡Ôñ²¿ÃÅ--" onchange="changedept()" >
</s:select>
 

<s:select list="titleMap" name="titleid" listKey="key" value="%{titleid}" listValue="value" headerKey="" headerValue="--ÇëÑ¡ÔñÖ°³Æ--" >
</s:select>

ÎÒÏë¸ù¾ÝÑ¡ÖеIJ¿ÃÅ£¬²éѯ³öÊôÓڸò¿ÃŵÄÖ°³Æ£¬Ôõô²éѯ·µ»ØºóµÄÊý¾Ý¡£

 function changedept(){
  var deptid=document.form1.deptid.value;
  loadXMLDoc("changeDeptUser.action?deptid="+deptid,checkReturn);//ÕâÀïÊDzéѯְ³ÆµÄ
  return null;
 }

½«´¦ÀíºóµÄÖ°³Æ½ÓÊÕÏÂÀ´£¬ÏÔʾÔÚÇ°¶ËÒ³Ãæ¾Í¿ÉÒÔÁË

AJAX ´¦Àíʱ£¬²»ÊÇÓÃÒ»¸ödataÂ𣡾ÍÊÇÓÃÀ´½ÓÊÕ·µ»ØÖµ µÄ


лл£¡ÎÒÏë·µ»ØÒ»¸ömap¶ÔÏó£¬È»ºó¸üе½£º< s:select list="titleMap">Ó¦¸ÃÔõô×ö 
ÒýÓÃ
CSS code

ÔÚ·þÎñÆ÷¶Ë·µ»ØÖ°³ÆµÄÐÅÏ¢£¬Èç·µ»ØÖ°³ÆnameºÍid£»·Ö±ð×ötextºÍvalue
public String execute() {
List list = getList(deptId);//ΪµÃµ½ÄãµÄÖ°³ÆÐÅÏ¢
String json = "[";
for (int i = 0; i < list.size(); i++) {
¡­¡­


ÓÃEL±í´ïʽ.

ÎÊÌâûÓнâ¾ö£¬ÓôÃÆ


Ïà¹ØÎÊ´ð£º

ajaxµÄÎÊÌâ - .NET¼¼Êõ / ASP.NET

ÎÒÅóÓѵÄÒ»¸öASP.NETÒýÓÃÁËajax¼¼Êõ£¬binĿ¼ÏÂÃæÒ²ÓÐajaxpro.dll£¬ÎªÊ²Ã´·þÎñÆ÷²»ÐèÒª°²×°ajax²å¼þÒ²¿ÉÒÔÔËÐÐÄØ£¬ÕÕÀí˵Ӧ¸ÃÒª°²×°ASPAJAXExtSetup.msi
ÓÐ ajaxpro.dll¾Í¿ÉÒÔÁË

²»Í¬µÄaajx×é¼þ
AjaxPro¾ÍÊÇ¿ò¼ ......

ajax¶ÁÈ¡ashxÊä³öµÄjsonÊý¾Ý±¨´í - .NET¼¼Êõ / C#

ÎÒÓÃjqueryÎÞË¢ÐÂÉÏ´«Í¼Æ¬ºó·µ»Øjson¸ñʽµÄÊý¾Ý±¨´í
£¨Êµ¼ÊÉÏͼƬÊÇÉÏ´«³É¹¦µÄÁË£¬Ö»ÊÇ·µ»Øjson¸ñʽ×ܶÁ²»µ½£¬×ÜÊDZ¨´í£©
ÎÒµ÷ÊÔÉÏ´«µÄashxÒ³ÈçÏÂ
ÎÞ·¨ÏÔʾ XML Ò³¡£ 
ʹÓà Ñùʽ±íÎÞ·¨²é¿´ XML ÊäÈë¡£Çë¸ü ......

ajax post·½Ê½Ìá½»Êý¾ÝÈçºÎ²Ù×÷£¿ - Web ¿ª·¢ / Ajax

RT£¡
xmlHttpRequest.send("Ìá½»²ÎÊýÃû=Öµ&Ìá½»²ÎÊýÃû1=Öµ");

var date={"Êý¾Ý1":"Êý¾Ý1Öµ","Êý¾Ý2":"Êý¾Ý2Öµ","Êý¾Ý3":"Êý¾Ý3Öµ" ......

AJAX ºǫ́Ôõôȡ²»µ½Ö± - .NET¼¼Êõ / ASP.NET

´úÂëÈçÏ Çë¸ßÊÖ Ö¸µãÏ лл
ajax_http.js
-------------
function getXMLHTTP() {
  var xmlhttp;
  if (window.ActiveXObject) {
  //IE
  try {
  ......

[¼±Óð¡] JSP+AJAX ÌøתÎÊÌâ. - Web ¿ª·¢ / Ajax

ÎÊÌâ: ÏÖÔÚÌá½»Ö®ºó¾Í²»ÄÜÌøµ½ajax.jsÖÐÖ¸¶¨µÄservlet 
  ¶øÊÇÓÖÖØнøÈëµ½ÁËpub_hotel_t.jspÒ³Ãæ. Ò²¾ÍÊÇûÓÐÖ´Ðе½ajaxÀïÃæÈ¥ ´ó¼Ò°ïæ¿´¿´ÊÇʲôԭÒò°É.
  ÊDz»ÊǺÍÌá½»µÄ°´Å¦ÓйØÄ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ