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

ajax ·µ»Øjson

µ±ÓÃajax·µ»Ø¶à¸öÖµµÄʱºò£¬¿ÉÒÔÓÃxml£¬Ò²¿ÉÒÔÓÃjson
jsonʵÀý
<html>
<head>
<title>AjaxTest</title>
<script type="text/javascript">
var xmlHttp;
function createXMLHttpRequest()
{
    if(window.ActiveXObject)
    {
        xmlHttp = new ActiveXObject("Microsoft.XMLHTTP");
    }
    else if(window.XMLHttpRequest)
    {
        xmlHttp = new XMLHttpRequest();
    }
}
function startRequest()
{
    createXMLHttpRequest();
    try
    {
        xmlHttp.onreadystatechange = handleStateChange;
        xmlHttp.open("GET", "Json.txt", true);
        xmlHttp.send(null);
    }
    catch(exception)
    {
        alert("xmlHttp Fail");
    }
}
function handleStateChange()
{    
    if(xmlHttp.readyState == 4)
    {        
        if (xmlHttp.status == 200 || xmlHttp.status == 0)
        {
            var result = xmlHttp.responseText;
            var json = eval("(" + result + ")");
           &nb


Ïà¹ØÎĵµ£º

ajax»º´æÎÊÌâ

ʹÓÃAjaxÖвéѯÊý¾Ý¿âʱ£¬Ö»µÚÒ»´Î²éѯÁËÊý¾Ý¿â£¬ÒÔºóÔÙÓÐÇëÇó¾Í²»Ìá½»¸ø·þÎñÆ÷´¦ÀíÁË
ҳͷµÄÇ建´æ±êǩûÆð×÷ÓÃ
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="expires" content="0">
½â¾ö·½·¨£º
1£º¼Óʱ¼ä´Á var url ......

ajax³£¼ûÎÊÌâ×ܽá


ÔÚ¿´ÎÄÕÂÇ°£¬ÏÈÖ¸¶¨Ò»¸öͨÓõıäÁ¿xhr£¬xhr´úÂëajax¶ÔÏó¡£
²âÊÔä¯ÀÀÆ÷£ºieΪie6£¬firefoxΪ2£¬ÆäËûµÄδ²âÊÔ¡£Í³³Æie6Ϊie£¬firefox2Ϊff¡£
»ù±¾µÄ
1£¬×î¾­µäµÄ¾ÍÊÇieϵĻº´æÎÊÌâÁË¡£
Èç¹ûʹÓõÄÊÇget£¬ÄÇôÔÚieϳöÏÖ»º´æÎÊÌâ¡£µ¼Ö´úÂëÖ»Ö´ÐÐÒ»´Î¡£½â¾ö°ì·¨¾ÍÊǼÓʱ¼ä´Á»òÕßËæ»úÊý£¬Ê¹url±äΪΨһ£¬ÕâÑù¾Í²»»á³öÏÖ ......

Java Web»ù´¡£ºµÚ¶þʮһ½² Ajax½»»¥µÄ»ù±¾¹ý³Ì

±¾ÎÄÄÚÈÝÕª×Ô£º¡¶Java Web¿ª·¢½Ì³Ì——ÈëÃÅÓëÌá¸ßƪ£¨JSP+Servlet£©¡·
½»»¥µÄ»ù±¾¹ý³Ì°üÀ¨£º
l         ´´½¨XMLHttpRequest¶ÔÏó£»
l         ·¢ËÍÇëÇó£»
l         ´¦ÀíÏìÓ¦¡£
´ ......

ajax ϵͳ´íÎó 1072896748

ÔÚʹÓÃJQueryµÄajax·ÃÎÊÒ³Ãæʱ£¬×ÜÊdzö´í£¬µÃ²»µ½·µ»ØµÄhtml´úÂ룬ÓÖ²»ÖªµÀ³öµÄʲô´í£¬°Ù˼²»µÃÆä½â
ÓÚÊǾÍÓÃXMLHTTPÈ¥·ÃÎÊ£¬½á¹ûÒ²³ö´í£¬²»¹ýÄܹ»µÃµ½´íÎóÔ­Òò£¬È»ºó¸ù¾Ý´íÎóÒòΪȥÍøÉϲ飬ÖÕÓڵõ½Á˴𰸡£¡£
Ô­À´jspµÄ±àÂëÓëjavaµÄ±àÂë²»Ò»ÖÂ
·½°¸¢Ù
 ´íÎó
<%@ page contentType="text/html;charset= ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ