WAP HttpConnectionÎÊÌâ
Java code:
public void run() {
gra.drawString("test",x,y,Graphics.LEFT| Graphics.TOP);
Font font = Font.getFont(Font.FACE_MONOSPACE, Font.STYLE_BOLD,
Font.SIZE_LARGE);
gra.setFont(font);
gra.setColor(0, 0, 0);
gra.drawRect(0, 0, this.getWidth(), this.getHeight());
// TODO Auto-generated method stub
javax.microedition.io.HttpConnection hc = null;
try {
hc = (HttpConnection) Connector
.open("http://110.43.5.66:8678/default.aspx");
} catch (IOException e1) {
// TODO Auto-generated catch block
e1.printStackTrace();
}
try {
System.out.println("connected");
System.out.println(hc.getResponseMessage());
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
DataInputStream dis = null;
try {
dis = hc.openDataInputStream();
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
int length = (int)hc.getLength();
byte[] b = new
Ïà¹ØÎÊ´ð£º
wap 1.0 wml ÒÔÏÂÊÇʲôÒâ˼£¿
<onevent type="onenterforward"> <refresh> <setvar name="txtUserName" value="" /> <setvar name="txtPassword" ......
ÎÒÓÃasp.net¿ª·¢wapÕ¾µã£¬Íê³ÉºóÈ¥http://validator.w3.org/ÕâÀïÑéÖ¤ÎÒµÄWapÒ³ÃæÊÇ·ñ±ê×¼£¬ÆäËüÎÊÌⶼ¸ÄºÃÁË£¬
¾ÍÊ£ÕâÒ»¸ö´íÎóÁË£¬°´×ÖÃæÒâ˼Àí½âÊÇ˵nameÊôÐÔÒÑ´æÔÚ£¬ÀàËÆÕâÑùµÄ´íÎó»¹Óв»ÄÜÓÃborder ,align,sizeµ ......
ÎÒÓÃ.net¿ª·¢wapÍøÕ¾
1£¬ÎÒ´Ó¹¤¾ßÏäÀïÍÏÁËÁ½¸ölink£¬ÕâÁ½¸ölink»áÏÔʾÔÚÁ½ÐУ¬Èç¹ûÈÃÕâÁ½¸ölink´¦ÓÚͬһÐС£
2£¬ÈçºÎÏÔʾÁ½¸ö¿Ø¼þÖ®¼äµÄ¿Õ¸ñÎÊÌâ¡£
¸úwapÓйØÂ𣿲»Ì«Ã÷°×
ÓÑÇé°ï¶¥¡£¡£¡£¡£¡£¡£¡£¡£¡£¡£
¾Í ......
ÎÒÔÚwmÉÏÓõçÐŵÄCDMAÍøÂ磬wap·½Ê½ÁªÍø£¬Á¬µÄÊÇ10.0.0.200£¬µ«ÊÇÿ´Î·¢ËÍÍêÊý¾Ýºó£¬½ÓÊÕµ½-1µÄ´íÎ󣬲»ÖªµÀΪʲô£¬·¢Ë͵İüµÄ¸ñʽÈçÏ£º
POST /sdread/portal.do?Id=0 HTTP/1.1
X-Online-Host: st30.sdread.net: ......
ÔÚweb.configÖÐÅäÖÃ
<globalization fileEncoding="UTF-8" requestEncoding="UTF-8" responseEncoding="UTF-8" />
aspxÒ³Ãæ
<%Response.ContentType = " ......