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

Struts2.0»ùÓÚxmlÅäÖÃÎļþ¶ÔActionµÄÊôÐÔ½øÐÐУÑé

java´úÂë
package com.xml.action;
import com.opensymphony.xwork2.ActionContext;
import com.opensymphony.xwork2.ActionSupport;
public class XMLAction extends ActionSupport{

private static final long serialVersionUID = 1L;
private String username;
private String mobile;
public void setUsername(String username) {
System.out.println("×¢Èëusername");
this.username = username;
}
public void setMobile(String mobile) {
System.out.println("×¢Èëmobile");
this.mobile = mobile;
}

public String getUsername() {
System.out.println("½«username´«¸øvalidator");
return username;
}
public String getMobile() {
System.out.println("½«mobile´«¸øvalidator");
return mobile;
}
public String update(){
ActionContext.getContext().put("message", "¸üгɹ¦");
return "success";
}
public String save(){
ActionContext.getContext().put("message", "±£´æ³É¹¦");
return "success";
}
}
УÑéÆ÷ÅäÖÃÎļþ±ØÐëÓëactionÀàÃûÏàͬºóÃæ¸ú¸ö¹Ì¶¨¸ñʽ“-validation.xml”£¬ÇÒºÍactionÀà·ÅÔÚͬһ¸öpackageÏ¡£
XMLAction-validation.xmlÅäÖÃÎļþ´úÂë
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE validators PUBLIC
"-//OpenSymphony Group//XWork Validator 1.0.3//EN"
"http://www.opensymphony.com/xwork/xwork-validator-1.0.3.dtd">
<validators>
<!-- ActionÖÐҪУÑéµÄÊôÐÔÃû -->
<field name="username">
<!-- Ö¸¶¨Ð£ÑéÆ÷ -->
<field-validator type="requiredstring">
<param name="trim">true</param>
<message>Óû§Ãû²»ÄÜΪ¿Õ</message>
</field-validator>
<field-validator type="stringlength">
<param name="minLength">6</param>
<param name="maxLength">12</param>
<message>Óû§Ãû³¤¶È±ØÐëÔÚ6λµ½12λ֮¼ä</message>
</field-validator>
</field>
<field name="mobile">
<!-- Ö¸¶¨Ð£ÑéÆ÷ -->
<f


Ïà¹ØÎĵµ£º

Ajax ºÍ XML: ÎåÖÖ³£¼û Ajax ģʽ

Asynchronous JavaScript + XML£¨Ajax£©ÎÞÒÉÊÇ 2006 Äê×îÈÈÃŵļ¼ÊõÊõÓÇÒÓÐÍûÔÚ
2007 µÃµ½½øÒ»²½·¢Õ¹¡£µ«ÊǶÔÄúµÄÓ¦ÓóÌÐòÀ´ËµËü¾¿¾¹ÓÐʲôÒâÒåÄØ£¿Ajax Ó¦ÓóÌÐòÖÐÄÄÒ»ÖÖ³£¼û¼Ü¹¹Ä£Ê½Ó¦ÓÃ×î¹ã·ºÄØ£¿±¾ÎĽ«½éÉÜÎåÖÖ³£¼û
Ajax Éè¼Æģʽ£¬¿ÉÒÔʹÓÃËüÃÇ×÷Ϊ¹¤×÷µÄ»ù´¡¡£
µÄÈ·£¬Ajax
ÊÇ Web 2.0
ÈÈÃÅÊõÓËùÓÐÈ˶¼Ï£Íû ......

¼òµ¥µÄXMLÎļþ¶Áд £¨×ª£©

×¼±¸
¿ª·¢¹¤¾ß£ºVS2005£¬
Ç°Ì᣺°²×°msxml6½âÎöÆ÷£¬msÍøÕ¾¿ÉÏÂÔØ
ͨ¹ýÏòµ¼´´½¨VC++ MFC ¹¤³Ì£¬»ùÓÚ¶Ô»°¿ò
Ìí¼ÓÒýÓÃ:
//ÔÚStdAfx.hÖÐÒýÈ붯̬Á´½Ó¿â MSXML.DLL(C:\windows\system32\msxml6.dll)
#import <msxml6.dll>
±à¼­×ÊÔ´£¬Ìí¼Ó¿Ø¼þ
ÔÚbookid¶ÔÓ¦µÄÎı¾¿òÓÒ¼ü£¬Ìí¼Ó±äÁ¿°ó¶¨£¨ÈçÏÂͼ£¬°ó¶¨¿Ø¼þÖµ£¬±äÁ¿Ã ......

xml½âÎö



 
ʹÓÃSAX½âÎöºÍDOM½âÎöµÄʵÀý
ÊÕ²Ø



document.body.oncopy = function() {
if (window.clipboardData) {
s ......

SQL Server¸ù¾Ý²éѯ½á¹û,Éú³ÉXMLÎļþ

SQL Server¸ù¾Ý²éѯ½á¹û,Éú³ÉXMLÎļþ
À´Ô´£º²»Ïê  ×÷ÕߣºØýÃû  Ê±¼ä£º2009-3-6 22:15:58 ·¢²¼£ººÚ¿ÍÈí¼þÔ°
/*
'bcp' ²»ÊÇÄÚ²¿»òÍⲿÃüÁҲ²»ÊÇ¿ÉÔËÐеijÌÐò£¿
¿´¿´ÔÚC:\Program Files\Microsoft SQL Server\80\Tools\BinnÀïÃæÓÐûÓÐbcp.exeÕâ¸öÎļþ
È»ºó¿´¿´pathÀïÃæ¼ÓC:\Program Files\Microso ......

java½âÎöxmlµÄ¾ßÌåÁ÷³Ì

java ´úÂë
import javax.xml.parsers.DocumentBuilder;   
import javax.xml.parsers.DocumentBuilderFactory;   
  
import org.w3c.dom.Document;   
import org.w3c.dom.Element;   
import org.w3c.dom.NodeList;    ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ