asp.netÖеĹÖÒìÎÊÌ⣿
asp.netÖÐAÁ´½Ó´«ÖÐÎÄÖµ£¬½ÓÊÕʱÂÒÂ룡
ÔÚÓÐЩµçÄÔÉÏÄÜÕý³£½ÓÊÕ£¬µ«ÓÐЩµçÄÔÉÏÈ´²»ÄÜÕý³£½ÓÊÕ£¬
ÇëÎʸ÷λÓÐûÓÐʲô·½·¨£¿
ÓÃsession£¬»òÕ߸ü¸Ä±àÂ룬
default.aspx
C# code:
this.Redirect("hello.aspx?text="+this.this.Server.HtmlEncode("ÄãºÃ"));
hello.aspx
[code=C#
var text = this.this.Server.HtmlDecode(this.Request.QueryString["text"]);
[/code]
default.aspx
C# code:
this.Redirect("hello.aspx?text="+this.this.Server.HtmlEncode("ÄãºÃ"));
hello.aspx
C# code:
string text = this.Server.HtmlDecode(this.Request.QueryString["text"]);
UrlEncode
UrlDecode
or
ÉèÖÃÕ¾µãµÄ±àÂëÀàÐÍΪgb2312
ËüÖ»ÊÇ×îºóÒ»¸ö×ÖÂÒÂë£¬Ç°ÃæµÄ²»»áÂÒÂë
ÉèÖñàÂë
5Â¥µÄÁ½ÖÖ·½·¨¶¼¿ÉÒÔ
ÉÏÃæ¶¼»Ø´ðÁË
Ïà¹ØÎÊ´ð£º
aspÏÂÃæ£¬µ±Òª¸ù¾Ý²»Í¬µÄȨÏÞÏÔʾһЩ¹¦Äܰ´Å¥µÄ»°»áд³É
<%
if ȨÏÞ=1 then
%>
<input type="submit" name="Submit" value="Ìá½»" />
<%
end i ......
¸ÕѧÕâ¸ö£¬ËùÒÔÒ»¶ÑÎÊÌâÊÇûÃ÷°×µÄ
ÉèÖÃÁËCSSµÄÑùʽ£¬¸ü¸ÄΪÁ˾ø¶Ô¶¨Î»
µ«ÊÇÓÐʱºò¿Ø¼þ»¹ÊÇû°ì·¨Í϶¯···Ò»»á¿ÉÒÔÒ»»á²»¿ÉÒÔµÄÕâÊÇΪʲô°¡£¿
ÎÒÓõÄÊÇVS2008
²»ÊǺÜÃ÷°×£¬ÏÖÔÚÊÇÓÐÐ ......
ÀýÈçÓÐÁ½¶Î´úÂë
FirstPageCodeBehind.aspx
HTML code:
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="FirstPageCodeBehind.aspx.cs" Inherits="FirstPag ......
ÎÒÔÚasp.netÖÐÎÒÒª½«ËÄÕÅ»òËÄÕÅÒÔϵÄͼƬƴÔÚÒ»Æð£¬ÈçºÎʵÏÖ£¿Í¼Æ¬ÊÇÎÒ´ÓÊý¾Ý¿âÖжÁ³öÀ´µÄ¶þ½øÖÆ¡£µ¥ÕŶÁ³öÀ´µÄ´úÂëÈçÏ£ºC# code:
DataHelper dh=new DataHelper();
System.Drawing.Image image = dh.g ......
ÈçÌ⣡
FileUpload1.PostedFile.FileName
ÎÒÕâÑùдÁË µ«ÊÇ»¹ÊÇ»ñµÃµÄÊÇÒ»¸öÎļþµÄÃû³Æ£¬FileUpload1.FileName Õâ¸öÒ²ÊÇÒ»Ñù£¡
FileUpload1.PostedFile.FileName
IE ÎÊÌâ
¹¤¾ß-internetÑ¡Ïî-°²È«- ......