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

×Ô¶¨ÒåajaxµÇ¼µÄʱºò³öÏÖµÄÎÊÌâ

ÎÒдÁ˸ö¼òµ¥µÄajaxloginµÇ¼
Çé¿öÃèÊö
´ò¿ª2¸öÒ³Ãæ
µÚÒ»¸öÒ³ÃæÊÇajaxµÇ¼µÄÒ³Ãæ
µÚ¶þ¸öÒ³ÃæÊǵǼºóÊÕ±£»¤µÄÒ³Ãæ
µÇ¼µÚÒ»¸öÒ³Ãæ, ´ò¿ªÊܱ£»¤µÄÒ³Ãæ2, ÔÚµÚÒ»¸öÒ³ÃæµÇ³ö   ²¢Ë¢ÐµÚ2¸öÒ³ÃæÓÉÓÚÒѾ­µÇ³ö¾Í»á³öÏÖÌøµ½À¹½ØÒ³ÃæCASµÄlogin£¨ÕâÊÇÒѾ­°ÑÒªÌøתµÄÒ³Ãæ´æÔÚsessionÀïÁË£©
È»ºóÔÚµÚÒ»¸öµÇ¼ҳÃæµÇ¼ÓÉÓÚµÚÒ»¸öÒ³ÃæʱajaxÇëÇ󣬲¢ÇÒÔÚsessionÖÐÒѾ­´æÔÚËûÒªÌøתµÄÒ³Ã棬ËùÒԻ᷵»Ø¸ÃÌøתµÄÒ³Ã棬ajaxÖÐÉèÖÃÁËÖ»ÄܽÓÊÜjson¶ÔÏóÒò´Ë¾Í»á³öÏֵǼerrorÆäʵÒѾ­µÇÈëÁË
sessionÖдæµÄÌøתURLµÄ¸ñʽÊÇ
 
  session
 
  {SPRING_SECURITY_SAVED_REQUEST_KEY=SavedRequest[http://localhost:8080/AVerPortal/resourceAction/resourceIndex.action]}
ÆäʵÕâÊǸöÇëÇó·â×°¼´¶ÔÓÚÒ³Ãæhttp://localhost:8080/AVerPortal/resourceAction/resourceIndex.actionµÄÇëÇó
ÓÉÓÚÊÇ×Ô¶¨ÒåajaxloginÒò´Ëµ±ÓÐÀ¹½ØÄ¿±êµÄʱºò·µ»ØµÄÊÇÒ»¸öÇëÇó²»ÊÇÒ»¸öJSON¶ÔÏó¡£
½â¾ö·½°¸£ºÖØдԴ´úÂëÖеÄAbstractProcessingFilterÔÚÑéÖ¤³É¹¦Ê±ºòʹÓÃµÄ RedirectUtils.sendRedirectÀࣺÕâ¸ö·½·¨¹ËÃû˼ÒåÊÇÏñÒ³Ãæ·¢ËÍÒ»¸ö¶Ô·þÎñÆ÷¶ËÒ³ÃæµÄÇëÇó¡£response.sendRedirect(response.encodeRedirectURL(finalUrl));
¸Äд³É£º
StringBuffer str = new StringBuffer();
    str.append("{");
    str.append("status: \"true\",");
    str.append("url: \"");
    str.append(finalUrl);
    str.append("\"}");
    response.getWriter().write(str.toString());
×¢ÒâÕâÀïµÄÎÒÔ­À´Ð´³É
StringBuffer str = new StringBuffer();
    str.append("{");
    str.append("status: true,");
    str.append("url: ");
    str.append(finalUrl);
    str.append("}");
    response.getWriter().write(str.toString());
½á¹ûÔÚǰ̨ȴµÃµ½
   {status: true,url:  http://localhost:8080/AVerPortalTest/resourceAction/resourceIndex.action}
{status: true,url:  http://localhost:8080/AVerPortalTest/resourceAction/resourceIndex.action}
2·ÝJSON¶ÔÏóÔ­ÒòÊÇÒòΪJSON¸ñʽ£¬ÕýÈ·¸ñʽÈçÏÂ
{
status:"true",
&nbs


Ïà¹ØÎĵµ£º

AJAX Follow Me

×î½üÍøÉÏÌáµÄºÜ¶àµÄÒ»¸öиÅÄî¾ÍÊÇ AJAX ÁË, ÄÇô, AJAX ÊÇʲôÄØ? ÒÔÏÂÄÚÈÝÒýÓÃÍøÉÏ×ÊÁÏ:
AJAXÈ«³ÆΪ“Asynchronous JavaScript and XML”£¨Òì²½JavaScriptºÍXML£©£¬ÊÇÖ¸Ò»ÖÖ´´½¨½»»¥Ê½ÍøÒ³Ó¦ÓõÄÍøÒ³¿ª·¢¼¼Êõ¡£ËüÓлúµØ°üº¬ÁËÒÔϼ¸ÖÖ¼¼Êõ£º
Ajax£¨Asynchronous JavaScript + XML£©µÄ¶¨Òå
»ùÓÚ web±ê×¼£¨sta ......

´ÓÁ㿪ʼѧϰjQuery (Áù) AJAX¿ì²Í

Ò».ÕªÒª
±¾ÏµÁÐÎÄÕ½«´øÄú½øÈëjQueryµÄ¾«²ÊÊÀ½ç, ÆäÖÐÓкܶà×÷Õß¾ßÌåµÄʹÓþ­ÑéºÍ½â¾ö·½°¸, 
¼´Ê¹Äã»áʹÓÃjQueryÒ²ÄÜÔÚÔĶÁÖз¢ÏÖЩÐíÃؼ®.
±¾ÆªÎÄÕ½²½âÈçºÎʹÓÃjQuery·½±ã¿ì½ÝµÄʵÏÖAjax¹¦ÄÜ.ͳһËùÓпª·¢ÈËÔ±
ʹÓÃAjaxµÄ·½Ê½.
¶þ.Ç°ÑÔ
AjaxÈÃÓû§Ò³Ãæ·á¸»ÆðÀ´, ÔöÇ¿ÁËÓû§ÌåÑé.
ʹÓÃAjaxÊÇËùÓÐWeb¿ª·¢µÄ±Ø ......

Ajaxѧϰ±Ê¼Ç£¨Ò»£©

    ¶ÔÓëÈÎÒâÒ»ÃÅÓïÑÔµÄѧϰ£¬ÎÒÃÇ´ó¶¼ÊÇ´Ó»ù´¡¿ªÊ¼£¬¶ø¶ÔÓÚAjaxµÄѧϰÎÒÃÇ´ó¿É²»±Ø£¬ÒòΪËü±¾Éí¾Í²»ÊÇÒ»ÃÅеÄÓïÑÔ£¬Ajax=Asynchronous javascript and xml¡£·ôdzµÄ˵£¬Ëü¾ÍÊÇ»ù±¾ÓïÑÔ»ìºÏÓ¦ÓõĽá¹û£¬ÕýÓÉÓÚÕâÖÖ»ìºÏ²»ÊÇËæÐÄËùÓû£¬ÈÎÒâ¹´¶ÒµÄ£¬²Å  ÓÐÁ˳Éϵͳ£¬³É¹æ·¶µÄAjax¡£
Ϊ´Ë£¬ÎÒÃÇÒ»¿ªÊ¼¾Í´Ó ......

ASP.NET AJAXµ÷ÓÃWebService

ÈçºÎÔÚ¿Í»§¶ËÖ±½Óµ÷ÓÃWebServiceÖеķ½·¨£¿
ÕâÀï½áºÏ¾­Ñé×Ô¼ºÐ´Ò»Ð´
1.Ê×ÏÈн¨Ò»¸ö ASP.NET AJAX-Enabled Web Site,ÕâÑùϵͳΪÎÒÃÇ×Ô¶¯ÅäÖúÃÁË»·¾³£¬ÕâÖ÷ÒªÌåÏÖÔÚWeb.configÕâ¸öÎļþÉÏ£¬Èç¹ûÒÑÓÐÍøÕ¾²»ÊÇASP.NET AJAX-Enabled Web SiteÒ²¿ÉÒÔ¶ÔÕÕÐÞ¸ÄÏÂWeb.config£¬Ò²¿ÉÒÔ´ïµ½ÏàͬµÄЧ¹û¡£
2.н¨Ò»¸öweb·þÎñ£¬WebSer ......

AJAXÈçºÎÓÃÓÚWeb²¿¼þ

Ô­ÎĵØÖ·£ºhttp://sharethispoint.com/archive/2006/11/15/Build-web-parts-with-ajax.aspx
ÈçºÎÔÚ¿ª·¢Web²¿¼þʱʹÓÃajaxÄØ£¿ÎÒÃǽ«ÒÔÒ»¸öÑù×ÓÀàËÆMOSS 2007ÖÐKPIºÍBDC Web²¿¼þµÄWebPartΪÀýÀ´ËµÃ÷¡£Èç¹ûÄã¶ÔajaxÒ»µã¶¼²»Á˽â,ÍƼöѧϰTerryLeeµÄajaxÈëÃÅϵÁС£
ASP.net2.0ÓÐÒ»¸öºÜ¿áµÄÐÂÌØÐÔ½Ð×÷¿Í»§¶Ë½Å±¾»Øµ÷¡£½Å±¾»Øµ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ