.net 3.5 ajax¿ò¼ÜÎÞ·¨¼ÓÔØ - Web ¿ª·¢ / Ajax
ʹÓÃ.net 3.5 ×Ô´øµÄajax¿Ø¼þ£¬ÔÚIE7¡¢IE8ÏÂÌáʾ ajax¿ò¼ÜÎÞ·¨¼ÓÔØ
Ò³Ãæ½á¹¹ÈçÏ£º
HTML code:
<form id="form1" runat="server">
<asp:ScriptManager ID="SM" runat="server">
</asp:ScriptManager>
<asp:UpdatePanel ID="UP" runat="server">
<ContentTemplate>
//×Ô¶¨Òå´úÂë
</ContentTemplate>
</asp:UpdatePanel>
</form>
vs×Ô´øµÄajax¿ò¼Ü£¬¾ÍÊÇÀ¬»ø
ÀÏÐÖ£¬Ôõô²»Ôç˵°¡£¬¿ÉÊÇÏÖÔÚÏîÄ¿µ±ÖÐÒѾÓÃÁË£¬Çó½â
{{
Ïà¹ØÎÊ´ð£º
ÎÒÏÖÔÚÓÃstruts2¿ò¼ÜÖÐÐèҪʹÓÃajaxʵÏÖ¾Ö²¿Ë¢Ð£¬µ«ÊÇ´ÓÈÝÆ÷Àï·µ»ØµÄÖµ²»ÖªµÀÔõô´Óstruts.xmlÅäÖÃÎļþÀïÓ³Éäµ½jspÒ³ÃæÀÒÔÇ°servletÀïдout.orint("xxxxx")¾Í¿ÉÒԵõ½~£¬µ«ÊÇÏÖÔÚÓÃstruts¾Í²»ÖªµÀÔõô ......
ÎÒÅóÓѵÄÒ»¸öASP.NETÒýÓÃÁËajax¼¼Êõ£¬binĿ¼ÏÂÃæÒ²ÓÐajaxpro.dll£¬ÎªÊ²Ã´·þÎñÆ÷²»ÐèÒª°²×°ajax²å¼þÒ²¿ÉÒÔÔËÐÐÄØ£¬ÕÕÀí˵Ӧ¸ÃÒª°²×°ASPAJAXExtSetup.msi
ÓÐ ajaxpro.dll¾Í¿ÉÒÔÁË
²»Í¬µÄaajx×é¼þ
AjaxPro¾ÍÊÇ¿ò¼ ......
RT£¡
xmlHttpRequest.send("Ìá½»²ÎÊýÃû=Öµ&Ìá½»²ÎÊýÃû1=Öµ");
var date={"Êý¾Ý1":"Êý¾Ý1Öµ","Êý¾Ý2":"Êý¾Ý2Öµ","Êý¾Ý3":"Êý¾Ý3Öµ" ......
Êý¾Ý¿âÒѾ·ÅÁ˶àÌõ¼Ç¼£¬¼ì²âµÄ¶¼ÊÇÓ¢Îĵģ¬¿ÉÊÇÓÐЩÓû§Ãû¿ÉÒÔÕý³£¼ì²â³öÒѱ»×¢²áÁË£¬ÓÐЩÓû§ÃûÊý¾Ý¿âÖÐȷʵ´æÔڵĵ«¾ÍÊǼì²â²»³öÒÑ´æÔÚ£¨ÔÚ×¢²áÒ³Ã滹ÊÇÏÔʾδ±»×¢²á£©£¬±ÈÈçÊý¾Ý¿âÖÐÓÐ Ò»¸öÓû§ÃûΪ£ºlb Î񱒵 ......
ÎÊÌâÈçÌâ¡£
AjaxµÄ´úÂë:
JScript code:
function getProfession2(){
var department=document.getElementById("department").value;
alert(department+"-----&qu ......