asp.net utf 8 ÖÐÎÄÂÒÂëÎÊÌâ
Unicode ±àÂëÕýÖð½¥³ÉΪ¶àÓïÑÔÖ§³ÖµÄ×îͨÓýâ¾ö·½°¸¡£²ÉÓà Unicode ±àÂëµÄÖÐÎÄÍøÒ³ÄÜÔÚ¸÷ÖÖƽ̨¡¢¸÷ÖÖÀàµÄä¯ÀÀÆ÷É϶¼µÃµ½ºÜºÃµÄ¼æÈÝ¡£utf-8 ÊÇ Unicode µÄÒ»ÖÖ´æ´¢/½»»»ÊµÏÖ·½Ê½¡£¶ÔÓÚ²»Í¬ÊýÖµ·¶Î§µÄ Unicode Â룬Ëü²ÉÓñ䳤µÄ·½Ê½À´±àÂ룺ËùÓÐ ASCII ×Ö·ûÕ¼ÓÃ1¸ö×Ö½Ú£¬´óÓÚ 0x7f µÄÔòÕ¼ÓÃ2µ½4×Ö½Ú²»µÈ¡£¿ÉÒÔ¿´³ö£¬ËùÓÐ ASCII ÎļþÖ±½Ó¼æÈÝ utf-8¡£ÁíÍ⣬¶ÔÓÚÍøÒ³Ô´´úÂëÕâÑù ASCII ×Ö·ûÕ¼ÄÚÈݺܴ󲿷ֵÄÎļþÀ´Ëµ£¬Ëüͨ³£±ÈÆäËû Unicode ´æ´¢/½»»»¸ñʽ£¨Èçutf-16£¬utf-32µÈ£©¸ü½ÚÊ¡¿Õ¼ä¡£Òò´Ë£¬utf-8 ¸ñʽÒÑÔÚÍøÕ¾Éè¼ÆÖй㷺µÄʹÓá£
µ«ÊÇ£¬ÔÚ asp.net ÖÐÎÄÍøÒ³ÖÐʹÓà utf-8 ±àÂëʱ£¬ÉÔ²»Ð¡ÐľͻáÔì³ÉÖÐÎÄÂÒÂ룬ÁîÈËÍ·ÌÛ¡£¶ÔÓÚÕâ¸öÎÊÌ⣬ÍøÉϺܶàµØ·½½¨Ò飺ÔÚ±ØÒªµÄµØ·½ÈÔʹÓà GB2312 ±àÂë¡£ÕâÑùÏÔÈ»²»ÊÇÒ»¸ö³¹µ×µÄ½â¾ö·½°¸¡£±¾ÎÄÌÖÂÛÁËÈçºÎÈçºÎÔÚ asp.net ÍøÕ¾ÖÐÍêȫʹÓà utf-8 ±àÂë¡£
ÔÚ Visual Studio 2005 ÖÐн¨Ò»¸ö asp.net Õ¾µã¡£ÔÚ web.config ÎļþÖÐÉèÖÃÕ¾µãʹÓà utf-8 ±àÂ룺
<?xml version="1.0"?>
...
<configuration>
<system.web>
<globalization fileEncoding="utf-8" />
</system.web>
<configuration>
...
ÕâÑùÒ»À´£¬VS ¿ÉÒÔÔÚÒ»¶¨³Ì¶ÈÉÏʵÏÖ¶Ô utf-8 µÄ×Ô¶¯»¯Ö§³Ö£¬µ«²»ÊǺÜÍêÉÆ¡£¾³£»¹ÊÇ»áÓÐÂÒÂëÎÊÌâ¡£ÏÂÃæµÄÌÖÂÛÔÚ¼´Ê¹Ã»ÓÐÉèÖÃÕ¾µã±àÂëµÄÇé¿öÏÂÒÀÈ»ÄÜÓÐЧ½â¾öÖÐÎÄÂÒÂëÎÊÌâ¡£
´´½¨Ò»¸ö asp.net Ò³Ã棬²¢±àд´úÂëÈçÏ£º
<%--sample.aspx--%>
<%@ Page Language="C#" AutoEventWireup="true"
CodeFile="sample.aspx.cs" Inherits="sample" %>
<!DOCTYPE html PUBLIC
"-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title>²âÊÔ</title>
</head>
<body>
<form id="form1" runat="server">
<asp:RadioButtonList ID="RadioButtonList1" runat="server">
<asp:ListItem>¾ÉÈÕÖØÀ´</asp:ListItem>
<asp:ListItem>http://live.mingliang.org</asp:ListItem>
</asp:RadioButtonList>
<asp:Button ID="Button1" runat="server" Text="Submit"
Ïà¹ØÎĵµ£º
ÈçºÎ°Ñ²Ù×÷µÄÊý¾ÝÌí¼Óµ½Êý¾Ý¿âÖУ¿
н¨´¥·¢Æ÷µÄ·½·¨¼°ÔÀí£¿
½ÌʦÈçºÎÌí¼Ó(Éϱ¨)¿ÎÌ⣬ÊÇ·ñÊÇÓÃEXCEL»òÊÇÆäËûµÄ·½·¨OR add task£¨°üÀ¨ä¯ÀÀ¿ÎÌâ¡¢²éÔÄѧÉúÑ¡ÌâÇé¿ö£©£¿
½ÌʦÉóÉóºËÊÇ·ñͨ¹ý£¿
PLAN:
¸ü¸Ä¸öÈËÐÅÏ¢¡¢ÃÜÂëµÈ
½ÌʦµÇ¼¡¢Éϱ¨¿ÎÌâ ( ¼´ÊÇInsert Óï¾ä)£Û Ìí¼Ó¿ÎÌâ ¡¢¿ÎÌâä¯ÀÀ £Ý
½ÌÊ¦È ......
0¡¢ÒýÑÔ
Web Ò³ÃæÊÇÎÞ״̬µÄ£¬ ·þÎñÆ÷¶Ôÿһ´ÎÇëÇó¶¼ÈÏΪÀ´×Ô²»Í¬Óû§£¬Òò´Ë£¬±äÁ¿µÄ״̬ÔÚÁ¬Ðø¶ÔͬһҳÃæµÄ¶à´ÎÇëÇóÖ®¼ä»òÔÚÒ³ÃæÌøתʱ²»»á±»±£Áô¡£ÔÚÓÃAsp.NET Éè¼Æ¿ª·¢Ò»¸öWebϵͳʱ£¬ Óöµ½Ò»¸öÖØÒªµÄÎÊÌâÊÇÈçºÎ±£Ö¤Êý¾ÝÔÚÒ³Ãæ¼ä½øÐÐÕýÈ·¡¢°²È«ºÍ¸ßЧµØ´«ËÍ£¬Asp.net ÌṩÁË״̬¹ÜÀíµÈ¶àÖÖ¼¼ÊõÀ´½â¾ ......
(1) ASP.NET µÄÊý¾ÝÑéÖ¤¿Õ¼þRegularExpressionValidator ʵÏÖÑéÖ¤FileUpLoadÉÏ´«ÎļþµÄÀàÐÍ
<asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" ControlToValidate="FileUpload1"
ErrorMessage="¸ñʽ²»×¼È·£¬Ö»ÄÜ(.jpg|.JPG|.gif|.G ......
MVC(¼´Ä£ÐÍ-ÊÓͼ-¿ØÖÆÆ÷)
MVC(Model-View-Controller)ÓÃÓÚ±íʾһÖÖÈí¼þ¼Ü¹¹Ä£Ê½.Ëü°ÑÈí¼þϵͳ·ÖΪÈý¸ö»ù±¾²¿·Ö:Ä£ÐÍ(Model),
ÊÓͼ(View)ºÍ¿ØÖÆÆ÷(Controller)
MVCµÄÓŵ㣺
1¶à¸öÊÓͼ¶ÔÓ¦Ò»¸öÄ£Ð͵ÄÄÜÁ¦
......
ÏÖÔÚÖ÷Á÷µÄÍøÕ¾¿ª·¢ÓïÑÔÎÞÍâºõasp¡¢php¡¢asp.net¡¢jspµÈ¡£
ÍøÒ³´Ó¿ªÊ¼¼òµ¥µÄhmtlµ½¸´ÔӵķþÎñÓïÑÔ£¬×ß¹ýÁË10¶à¸öÄêÍ·£¬¸÷ÖÖ¼¼Êõ²ã³ö²»Çµ¥¸öµÄÖ÷Á÷¼¼ÊõÒ²ÔÚ²»¶Ï·Ðµİ汾£¬ÏÖÔÚ·ÖÎöϸ÷ÖÖÓïÑÔµÄÇø±ð¡¢ÓÅÊÆ¡¢ÁÓÊÆ¡¢¿ª·¢×¢ÒâÊÂÏ
HTML:µ±È»ÕâÊÇÍøÒ³×î»ù±¾µÄÓïÑÔ,ÿһ¸ö·þÎñÆ÷ÓïÑÔ¶¼ÐèÒªËüµÄÖ§³Ö,Ҫѧϰ,Õâ¸ö¿Ï¶¨ÊÇ¿ª ......