- ä¯ÀÀÆ÷Ö§³ÖÇé¿ö¼ì²â
- ModernizrÊÇÒ»¸ö¿ªÔ´µÄJavaScript½Å±¾¿â£¬¿ÉÒÔÓÃËüÀ´¼ì²éä¯ÀÀÆ÷¶ÔHTML5ºÍCSS3µÄÖ§³ÖÇé¿ö¡£
- IEÊǸöºÜÓÐÒâ˼µÄä¯ÀÀÆ÷£¬Ëüֻʶ±ðËüµÄDOM×ÖµäÀï´æÔڵıêÇ©¡£Èç¹ûÄãµÄHTMLÖаüº¬Ëü²»ÈÏʶµÄ±êÇ©£¬Ö»ÐèÒªÓÃJavaScript´´½¨Ò»Ï£¬IE¾Í»á°Ñ¸Ã±êÇ©¼Óµ½ËüµÄDOM×ÖµäÖУ¬ÄÇôҲ¾Í¿ÉÒÔʶ±ð¸Ã±êÇ©²¢ÎªËüÓ¦ÓÃÑùʽÁË¡£ÀýÈ磬ÈÃIEÖ§³Öarticle±êÇ©µÄ·½·¨ÊÇ£º
1
document.createElement(¡°article¡±)
1
<!--[
if
lt IE 9]>
2
<script>
3
var
e = (
"abbr,article,aside,audio,canvas,datalist,details,"
+
"figure,footer,header,hgroup,mark,menu,meter,nav,output,"
+
"progress,section,time,video"
).split(
','
);
4
for
(
var
i = 0; i < e.length; i++)
5
{
6
document.createElement(e[i]);
7
}
8
</script>
9
<![endif]¡ª>
1
<!--[
if
lt IE 9]>
2
<script src=
"http://html5shiv.googlecode.com/svn/trunk/html5.js"
></script>
3
<![endif]-->
- ORIGIN£¨Ô´£©
- HTML5ͨ¹ýÒýÈëoriginÕâ¸ö¸ÅÄîÀ´Ã÷È·ºÍϸ»¯ÁËÓò°²È«ÐÔ£¬originÊÇÓÉscheme£¨ÐÒ飩¡¢host£¨ÓòÃû£©ºÍport£¨¶Ë¿Ú£©×é³ÉµÄ¡£Æ©Èçhttp://windstyle.cnºÍhttps://windstyle.cnÊDz»Í¬µÄorigin£¬µ«http://windstyle.cnºÍhttp://windstyle.cn/example.htmlÊÇͬһorigin¡£
- DOCTYPE
- WebÒ³ÃæÓм¸ÖÖ²»Í¬µÄäÖȾģʽ£º
- Standards mode
- Almost Standards mode
- Quirk mode
- DOCTYPE¾ÍÊÇÓÃÀ´¸æËßä¯ÀÀÆ÷Ó¦¸ÃÓÃÄÄÖÖģʽÀ´äÖȾҳÃ棬·ûºÏHTML5±ê×¼£¨Standards mode£©µÄDOCTYPEºÜ¼òµ¥£º
1
<!DOCTYPE HTML>
- ûÓÐDOCTYPE»òÕßÉùÃ÷Á˲»Í¬µÄDOCTYPE»áµ¼ÖÂä¯ÀÀÆ÷ÒÔAlmost Standards mode»òQuirks modeÀ´äÖȾҳÃæ¡£¡¶HTML5 Up and Running¡·µÄ×÷Õß˵£¬Ä¿Ç°ÖÁÉÙÓÐ5ÖÖDOCTYPE £¬ËüÃǻᴥ·¢ä¯ÀÀÆ÷µÄalmost standards modeºÍÖÁÉÙ73ÖÖquirks mode£¬¹âIE8¾ÍÖ§³Ö4ÖÖ³ÊÏÖģʽ£¨¼ûÏÂͼ£©£¬ÓÚÊÇ×÷ÕßÔÚÊéÖÐÒª´óº°£º¡°Kill it. Kill it with fire!¡±¡£
- WebÒ³ÃæÓм¸ÖÖ²»Í¬µÄäÖȾģʽ£º
- Îĵµ´ó¸Ù
- ÔÚHTML4ÖУ¬´´½¨Îĵµ´ó¸ÙµÄΨһ·½·¨ÊÇʹÓÃ<h1>µ½<h6>Õ⼸¸ö±êÇ©£¬ÎªÁËÈ·±£´ó¸ÙÖ»ÓÐÒ»¸ö¸ù½Úµã£¬Ò³ÃæÖоͲ»Äܶà´ÎʹÓÃ<h1>¡£¶øÔÚHTML5ÖУ¬Ã¿¸ösection¶¼¿ÉÒÔ°üº¬×Ô¼ºµÄ<h1>£¬Õâ²¢²»»áÓ°Ïì´ó¸Ù½á¹¹¡£
- <time>±êÇ©
- Ó÷¨Ê¾Àý£º
1
<
time
datetime
=
"2009-10-22T13:59:47-04:00"
pubdate> October 22, 2009 1:59pm EDT </
time
>
- pubdateÌØÐÔÓÐÁ½¸öº¬Ò壬Èç¹û<time>±êǩλÓÚ<article>±êÇ©ÖУ¬pubdate±íʾ¸ÃarticleµÄ·¢²¼ÈÕÆÚ£¬·ñÔò£¬pubdate±íʾÕû¸öÎĵµµÄ·¢²¼ÈÕÆÚ¡£
- Ó÷¨Ê¾Àý£º
- <canvas>±êÇ©
- ÉèÖÃ<canvas>±êÇ©µÄ¿í¶È»ò¸ß¶È»áÇå³ýËüµÄÄÚÈÝ£¬²¢ÇÒ»¹»á½«»æͼÉÏÏÂÎÄÖеÄËùÓÐÊôÐÔÖØÉèΪĬÈÏÖµ¡£IEÄ¿Ç°Éϲ»Ö§³Ö<canvas>£¬¿ÉÒÔʹÓÃExplorerCanvasÕâ¸ö¿ªÔ´µÄJavaScript½Å±¾¿âÀ´¼ä½ÓʵÏÖ»²¼API¡£
- Ïòcontext.drawImage·½·¨´«µÝimg¶ÔÏó¿ÉÒÔ½«img±íʾµÄͼƬ»æÖÆÔÚ»²¼ÉÏ£¬µ«imgËùÒýÓõÄͼƬ±ØÐëÍêÈ«¼ÓÔØÍê±Ï£¬·ñÔò»áÅ׳öÒì³£¡£
- Èç¹ûÏòcontext.drawImage·½·¨´«µÝvideo¶ÔÏó£¬ÄÇô½«»áÔÚ»²¼ÉÏ»æÖÆÊÓƵµÄµ±Ç°Ö¡»Ãæ¡£
- context.getImageData·½·¨¿ÉÒÔ»ñÈ¡»²¼µÄÏñËØÊý¾Ý£¬µ«Èç¹û»²¼ÉÏ»æÖÆÁËÀ´×Ô²»Í¬originµÄͼƬʱ£¬µ÷Óô˷½·¨»áÅ׳öÒì³£¡£
- Web Storage
- CookieµÄȱµã£º
- ÿ´ÎHTTPÇëÇ󶼻á°üº¬Cookie£¬»á½µµÍÇëÇóËٶȣ»
- CookieÊý¾Ýδ¼ÓÃÜ£¬ÔÚ²»Ê¹ÓÃSSLµÄÇé¿öϲ»°²È«£»
- CookieµÄ³ß´çÏÞÖÆΪ4KB
- LocalStorageºÍsessionStorageµÄÊý¾ÝÒÔ×Ö·û´®¼üÖµ¶ÔµÄÐÎʽ´¢´æ£¬ËûÃǵÄÇø±ðÈçÏ£º
- Éú´æÖÜÆÚ²»Í¬£ºµ±°üº¬Ò³ÃæµÄÑ¡Ï»òÕß´°¿Ú¹Ø±Õºó£¬sessionStorageÖд洢µÄÊý¾Ý¾ÍÇå¿ÕÁË£¬¶øLocalStorageÖд洢µÄÊý¾ÝÒÀÈ»´æÔÚ£»
- Êý¾Ý¿É¼û¶È²»Í¬£ºsessionStorageÖд洢µÄÊý¾ÝÖ»Óе±Ç°Ò³Ãæ¿ÉÒÔ·ÃÎÊ£¬¶øLocalStorage´æ´¢µÄÊý¾Ý¶ÔÏàͬoriginµÄËùÓÐÒ³Ã涼¿É¼û¡£
- Web Storageʼþ»áÔÚÏàͬoriginµÄËùÓÐÒ³ÃæÉÏ´¥·¢£¬ÎÞÂÛ¸ÃÒ³ÃæÊÇ·ñ¶ÔWeb Storage½øÐйý²Ù×÷£¬ËùÒÔ¿ÉÒÔÀûÓÃÕâЩʼþÀ´½øÐÐÒ³ÃæÖ®¼äµÄͨÐÅ¡£
- CookieµÄȱµã£º
- Offline Web Application
- Offline Web ApplicationÐèÒªÒ»¸öÀëÏßÇåµ¥Îļþ£¨*.manifest£©£¬¸ÃÎļþ¿ÉÒÔλÓÚ·þÎñÆ÷ÉϵÄÈκÎλÖ㬵«±ØÐëÒÔtext/cache-manifestΪÄÚÈÝÀàÐÍÌṩ¡£
- Offline Web ApplicationÖÐËùÓÐÒ³ÃæµÄ<html>±êÇ©Öж¼ÒªÌí¼ÓÖ¸Ïò¸ÃÇåµ¥ÎļþµÄmanifestÌØÐÔ¡£
- Çåµ¥ÎļþʾÀý£º
CACHE MANIFEST
FALLBACK: / /offline.html
NETWORK: * - ÎÞÂÛµ±Ç°ÊÇ·ñÔÚÏߣ¬CACHE MANIFESTÖеÄËùÓÐ×ÊÔ´¶¼»á±»»º´æÆðÀ´£»NETWORK½Ú±íʾ¡°°×Ãûµ¥¡±£¬¸Ã½ÚÖеÄËùÓÐ×ÊÔ´¶¼²»»á±»»º´æÏÂÀ´£¬Ö»ÄÜÔÚÏß»ñÈ¡£»FALLBACKÔòΪÄÇЩÎÞ·¨»ñÈ¡µÄ×ÊÔ´Ìṩһ¸ö±¸Ó÷¾¶¡£
- window.applicationCache¶ÔÏó°üº¬Ðí¶àʼþ
- µ±ä¯ÀÀÆ÷·¢ÏÖ<html>±êÇ©ÖеÄmanifestÌØÐÔʱ£¬¾Í»á´¥·¢checkingʼþ£»
- Èç¹ûä¯ÀÀÆ÷֮ǰ´Óδ¼û¹ý´ËÇåµ¥Îļþ£º
- ´¥·¢downloadingʼþ£¬È»ºó¿ªÊ¼ÏÂÔØÇåµ¥ÖеÄ×ÊÔ´¡£
- ÏÂÔعý³ÌÖлᴥ·¢progressʼþ£¬¸Ãʼþ°üº¬ÁËÒÑÏÂÔØÎļþµÄÊýÁ¿ºÍ´ýÏÂÔØÎļþµÄÊýÁ¿µÈÐÅÏ¢¡£
- Çåµ¥ÖеÄ×ÊÔ´¶¼ÏÂÔØÍê±Ïºó£¬»á´¥·¢cachedʼþ£¬Õâ±íÃ÷¸ÃOffline Web ApplicationÒѾ¿ÉÒÔÔÚÀëÏßʹÓÃÁË¡£
- Èç¹ûä¯ÀÀÆ÷֮ǰ·ÃÎʹý°üº¬Í¬Ò»Çåµ¥ÎļþµÄÒ³Ã棬¾Í»áÈ¥¼ì²é¸ÃÇåµ¥ÊÇ·ñ·¢ÉúÁ˱仯£º
- Èç¹ûûÓб仯£º´¥·¢noupdateʼþ£»
- Èç¹û·¢ÉúÁ˱仯£º»á´¥·¢downloadingʼþ£¬µ±Çåµ¥ÖеÄ×ÊÔ´¶¼ÏÂÔØÍê±Ïºó£¬»á´¥·¢updatereadyʼþ£¬Õâ±íÃ÷¸ÃOffline Web ApplicationÒѾ¸üгɹ¦¡£µ«ä¯ÀÀÆ÷ÈÔÈ»ÔÚʹÓþɰ汾£¬ÏëÒªÇл»µ½Ð°汾£¬ÐèÒªÊÖ¹¤µ÷ÓÃwindow.applicationCache.swapCache()·½·¨¡£
- ÆÚ¼äÈç¹û·¢ÉúÁË´íÎó£¬ÄÄÅÂÖ»ÓÐÒ»¸öÎļþÏÂÔØʧ°ÜÕâÑùµÄ´íÎ󣬶¼»áµ¼ÖÂÕû¸ö»º´æ¹ý³Ìʧ°Ü£¬²¢»á´¥·¢errorʼþ£¬×îÒªÃüµÄÊÇÕâ¸öʼþ²¢²»»á¸æËßÄã¾ßÌå´íÔÚÄÄÀï¡£
- window.applicationCache.statusָʾÁË»º´æµÄ״̬£º
- 0£ºUNCACHED
- 1£ºIDLE
- 2£ºCHECKING
- 3£ºDOWNLOADING
- 4£ºUPDATEREADY
- 5£ºOBSOLETE
- ¿ÉÒÔµ÷ÓÃwindow.applicationCache.update()·½·¨À´Ïòä¯ÀÀÆ÷ÇëÇó¸üлº´æ¡£
- Web ServerÓ¦µ±Í¨¹ýһЩHTTP headers£¨Æ©ÈçExpiresºÍCache-Control£©À´½«ÎļþµÄһЩÐÅÏ¢¸æËßä¯ÀÀÆ÷¡£Èç¹ûä¯ÀÀÆ÷ͨ¹ýHTTP headers·¢ÏÖÇåµ¥Îļþ¹ýÆÚ£¬¾Í»áÏò·þÎñÆ÷ÇëÇóа汾²¢ÏÂÔØËü¡£´Ëʱä¯ÀÀÆ÷»á½«·þÎñÆ÷ÉÏÒ»´Îͨ¹ýHTTP headers·¢Ë͸øËüµÄlast-modifiedʱ¼ä·¢»Ø¸ø·þÎñÆ÷£¬Èç¹û·þÎñÆ÷·¢ÏÖ·¢ÏÖÇåµ¥ÎļþÔÚ¸ÃÈÕÆÚÖ®ºó²¢Ã»Óиü¸Ä¹ý£¬¾Í»á·µ»Ø304״̬Â룬±íʾ¡°Note Modified¡±¡£Èç¹û·¢ÉúÁ˱仯£¬¾Í»á·µ»Ø200״̬ÂëÒÔ¼°ÐÂÎļþµÄÄÚÈÝ£¨µ±È»Ò²»á°üº¬Cache-ControlºÍеÄlast-modified headers£©£»
- ËùÒÔÿ´ÎÐÞ¸ÄÁËÐèÒª»º´æµÄÎļþÖ®ºó£¬¼Ç×ÅÒ²ÒªÐÞ¸ÄÇåµ¥Îļþ£¬ÕâÑù·þÎñÆ÷²Å»áÈÏΪËü¸üÐÂÁË°æ±¾¡£¼òµ¥µÄ·½·¨ÊÇÔÚÇåµ¥ÎļþÖмÓÒ»Ðа汾עÊÍ£¬Ã¿´ÎÐÞ¸Ä×¢ÊÍÖеİ汾ºÅ¼´¿É¡£
- µ±ä¯ÀÀÆ÷ÒÔÁª»ú·½Ê½¹¤×÷ʱ£¬navigator.onLineµÄֵΪtrue¡£
- Microdata
- MicrodataÓÃһЩ¾ßÓз¶Î§¸ÅÄîµÄÃûÖµ¶ÔÀ´Ú¹ÊÍDOM¡£
- ÔÚHTML5ÖУ¬<meta>±êÇ©¿ÉÒÔÔÚÈκεط½Ê¹Ó㬲»¾ÖÏÞÓÚ<head>ÖС£
- Google Rich Snippets tool¿ÉÒÔÌáÈ¡Ò³ÃæÖеÄMicrodata£¬²¢ÒÔ¡°Google See¡±µÄÐÎʽչÏÖ³öÀ´¡£
- Selector API
- ÐÂÔö¼ÓµÄºÍCSS SelectorÒ»ÑùµÄSelector API£¬¼ìË÷¸ü¼Ó¼òµ¥£º
1
querySelector(
"input.error"
);
//·µ»ØµÚÒ»¸öclassΪerrorµÄinput±êÇ©
1
querySelectorAll(
"#results td"
);
//¼ìË÷tdÖÐËùÓÐidΪresultsµÄ±êÇ©
- ÐÂÔö¼ÓµÄºÍCSS SelectorÒ»ÑùµÄSelector API£¬¼ìË÷¸ü¼Ó¼òµ¥£º
- ¶¨Î»
- ÐÂÔö¼ÓµÄ¶¨Î»·þÎñ»á·µ»ØÒÔϼ¸ÖÖ´íÎó£º
- PERMISSION_DENIED£¬´íÎó´úÂëΪ1£¬Óû§²»ÔÊÐíä¯ÀÀÆ÷·ÃÎÊλÖÃÐÅÏ¢£»
- POSITION_UNAVAILABLE£¬´íÎó´úÂëΪ2£¬»ñȡλÖÃʧ°Ü£»
- TIMEOUT£¬´íÎó´úÂëΪ3£¬³¬Ê±£»
- UNKNOWN_ERROR£¬´íÎó´úÂëΪ0£¬·¢ÉúÁËÆäËû´íÎ󣬿ÉÒÔ¼ì²émessageÌØÐÔÀ´»ñÈ¡¾ßÌåÐÅÏ¢
- ÐÂÔö¼ÓµÄ¶¨Î»·þÎñ»á·µ»ØÒÔϼ¸ÖÖ´íÎó£º
- ¿çÔ´
- XMLHttpRequest Level 2ÔÊÐíʹÓÃCross Origin Resource Sharing£¨CORS£©À´½øÐпçÔ´µÄHTTPÇëÇó¡£ÇëÇóÐèÒª°üº¬Ò»¸öOrigin header£¬ÓÃÓÚ¸æËß·þÎñÆ÷ÇëÇó´ÓºÎ¶øÀ´£¬´Ëheader±»ä¯ÀÀÆ÷±£»¤£¬Ó¦ÓõĴúÂëÎÞ·¨¸ü¸ÄËüµÄÖµ¡£Origin headerºÍÒÔÇ°µÄsic header²»Í¬Ö®´¦ÔÚÓÚºóÕßÊÇÍêÕûµÄURL¡£
- ³ýÁËä¯ÀÀÆ÷Òª×Ô¶¯·¢ËÍOrigin headerÐÅÏ¢Ö®Í⣬·þÎñÆ÷¶ËÒ²ÐèÒªÖ§³ÖCORS¡£ ¼ì²éä¯ÀÀÆ÷ÊÇ·ñÖ§³ÖXMLHttpRequest Level 2µÄ·½·¨ÊǼì²éXMLHttpRequest ÊÇ·ñ°üº¬withCredentialsÊôÐÔ¡£
- XMLHttpRequest Level 2µÄprogressʼþ°üÀ¨£º
- loadstart
- progress
- abort
- error
- load
- loadend
- WebSocket
- ÐÂÔö¼ÓµÄWebSocket APIÓÃÓÚÁ¬½ÓÔ¶³ÌÖ÷»ú£¬Ëü´ó·ù¶È¼õÉÙÁ˲»±ØÒªµÄHTTP header£¬´Ó¶øÌá¸ßÁ¬½ÓÁËËٶȡ£
- ws://ºÍwss://ÐÒé·Ö±ð±íʾWebSocketÁ¬½ÓºÍ°²È«WebSocketÁ¬½Ó¡£
- WebSocket APIÒ²ÐèÒª·þÎñÆ÷רÃÅÖ§³Ö¡£
- µ±ä¯ÀÀÆ÷ÇëÇóWebSocket URLʱ£¬·þÎñÆ÷»á»Ø·¢headersÀ´Íê³ÉWebSocketÎÕÊÖ£¬WebSocketÎÕÊÖÏìÓ¦µÄµÚÒ»ÐÐÄÚÈݱØÐëÊÇÏÂÃæµÄ¸ñʽ£º
HTTP/1.1 101 WebSocket Protocol Handshake
Íê³ÉÎÕÊֺ󣬿ͻ§¶ËºÍ·þÎñÆ÷¶ËÖ®¼ä¾Í¿ÉÒÔËæʱ·¢ËÍÏûÏ¢ÁË¡£ - WebSocket¶ÔÏó°üº¬ÒÔÏÂʼþ£º
- open£ºµ±Á¬½Ó½¨Á¢Ê±´¥·¢
- close£ºµ±Á¬½Ó¹Ø±Õʱ´¥·¢
- message£ºµ±ÊÕµ½ÏûϢʱ´¥·¢
- FORM API
- HTML5µÄinput±êÇ©Ôö¼ÓÁËÒ»¸öplaceholderÌØÐÔ£¬placeholderµÄÖµÖ»ÄÜ°üº¬Îı¾£¬²»¿ÉÒÔ°üº¬HTML±êÇ©¡£
- input±êÇ©µÄlistÌØÐÔºÍdatalist±êÇ©½áºÏÆðÀ´¿ÉÒÔΪinput±êÇ©Ìṩһ¸ö±¸Ñ¡ÁÐ±í¡£
- ÐÂÔö¼ÓµÄvalueAsNumberº¯Êý¿ÉÒÔ½«¿Ø¼þµÄÖµ´ÓÎı¾×ª»»ÎªÊý×Ö£¬¶øÇÒ»¹¿ÉÒÔ½«¿Ø¼þµÄÖµÉèÖÃΪÊý¾Ý¡£
- Èç¹ûinput¿Ø¼þÉèÖÃÁËrequiredÌØÐÔ£¬ÄÇô¸Ã¿Ø¼þ±ØÐë°üº¬Öµ£¬·ñÔò°üº¬ËüµÄForm¾ÍÎÞ·¨±»Ìá½»¡£
- ËùÓÐForm¿Ø¼þ¶¼°üº¬validityÊôÐÔ£¨ValidityState¶ÔÏ󣩣¬¸ÃÊôÐÔ°üÀ¨8ÖÖ¿ÉÄܵÄÑéÖ¤´íÎó£º
- valueMissing£ºÈ±ÉÙ±ØÐèÖµ£¨°üº¬requiredÌØÐÔµÄinput±êǩȱÉÙÖµ£©
- typeMismatch£ºÖµµÄÀàÐͲ»Æ¥Å䣨email¡¢urlµÈÀàÐÍУÑéʧ°Ü£©
- patternMismatch£ºÖµµÄ¸ñʽ²»Æ¥Å䣨input±êÇ©ÉèÖÃÁËpatternÌØÐÔ£¬µ«ÖµÃ»ÓÐÆ¥Åä¸Ãpattern¡£¿ª·¢ÈËÔ±¿ÉÒÔʹÓÃpatternÀ´¸ü¼ÓÁé»îµØÑéÖ¤Form¿Ø¼þµÄÖµ£©
- tooLong£ºÖµ³¬³öÁ˿ؼþÔÊÐíµÄ³¤¶È£¨³¬³öÁËmaxLengthÌØÐÔµÄÖµ£©
- rangeUnderflow£ºÖµÐ¡ÓÚÉ趨µÄ×îСֵ£¨ÖµÐ¡ÓÚminÌØÐÔµÄÖµ£©
- rangeOverflow£ºÖµ´óÓÚÉ趨µÄ×î´óÖµ£¨Öµ´óÓÚmaxÌØÐÔµÄÖµ£©
- stepMismatch£ºÖµ²»·ûºÏ¿Ø¼þµÄmin¡¢maxºÍstepÌØÐÔ×ۺϼÆËãµÄ½á¹û£¨±ÈÈçmin="0" max="100" step="5"£¬ÄÇôֵΪ6ʱ¾Í»áµ¼ÖÂstepMismatch£©
- customError£º±íʾÓÖ´úÂë²úÉúµÄ×Ô¶¨Òå´íÎ󣬵÷ÓÿؼþµÄsetCustomValidity(message)·½·¨¿ÉÒÔÉèÖÃcustomError£¬Ïò¸Ã·½·¨´«µÝ¿Õ×Ö·û´®»áÇå¿ÕcustomError¡£
- Èç¹ûForm¿Ø¼þÓпÉÄܽøÐÐÉÏÊöÈκÎÒ»ÏîÑéÖ¤£¬ÄÇôËüµÄwillValidateÊôÐԻ᷵»Øtrue¡£
- µ÷ÓÿؼþµÄcheckValidity·½·¨Ò²¿ÉÒÔ½øÐжԿؼþµÄÖµ½øÐÐÑéÖ¤¡£ ÎÞÂÛÊÇÌá½»Form»¹Êǵ÷ÓÃcheckValidity·½·¨£¬Èç¹ûFormÑé֤ʧ°Ü£¬¶¼»á´¥·¢invalidʼþ¡£
- ¿ÉÒÔͨ¹ý¿Ø¼þµÄvalidationMessageÊôÐÔÀ´·ÃÎʿؼþµÄÑé֤ʧ°ÜÏûÏ¢¡£ÏëÒª×èÖ¹ä¯ÀÀÆ÷ÏÔʾ´íÎóÏûÏ¢£¬¿ÉÒÔÔÚinvalidʼþÖе÷ÓòÎÊýevtµÄpreventDefault·½·¨¡£
- ÉèÖÃFormµÄnoValidateÌØÐÔ¿ÉÒÔʹÆ䲻ȥÑéÖ¤ÊäÈëµÄÓÐЧÐÔ£¬¹Ø±ÕÑéÖ¤µÄ¸ü¼òµ¥µÄ·½·¨ÊÇÉèÖÃÌá½»°´Å¥formNoValidateÌØÐÔ¡£
- Web Workers
- HTML5 Web WorkersΪWebÓ¦ÓÃÌṩÁ˺ǫ́¹¤×÷µÄÄÜÁ¦£¬Ê¹µÃJavaScript¿ÉÒÔÏíÊܵ½¶àºËCPUµÄºÃ´¦¡£
- Web Workers²»ÄÜÖ±½Ó·ÃÎÊÍøÒ³ºÍDOMAPI£¬ÕâÒ»µãºÍWindows FormsµÄ»úÖƺÜÏñ¡£
- ³õʼ»¯Web WorkdersʱÐèÒª´«µÝJavaScriptÎļþµÄURL£¬¸ÃÎļþ°üº¬ÁËWorkerÒªÖ´ÐеĴúÂ룺
1
worker =
new
Worker(
"echoWorker.js"
);
- Èç¹ûÏëÒªÔÚJavaScriptÎļþÖÐÒýÓÃÆäËûJavaScriptÎļþ£¬¿ÉÒÔµ÷ÓÃimportScripts·½·¨£¬´«µÝÒ»¸ö»ò¶à¸öJavaScriptÎļþµÄ·¾¶¡£
- ʵÀý»¯Web WorkerÖ®ºó£¬¾Í¿ÉÒÔµ÷ÓÃpostMessage APIÀ´ÔÚÍøÒ³ºÍWeb WorkerÖ®¼ä·¢ËÍÊý¾ÝÁË¡£
ÍƼöÐÅÏ¢
- CSS²¼¾ÖµÄ8¸öÄãÐèÒªÕÆÎյļ¼ÇÉ
- IE6¡¢IE7 ¡¢IE8¡¢FFµÄCSSHack
- ̽¾¿cssÖи÷ÖÖÇé¿öϵÄÔªËصĴ¹Ö±ºÍˮƽ¾ÓÖеÄÎÊÌâ
- YahooÍŶӾÑ飺ÍøÕ¾ÐÔÄÜÓÅ»¯µÄ34Ìõ»Æ½ð·¨Ôò(ת)
- HTMLÖÐÀûÓÃ404½«ÀÏÓòÃûÖض¨Ïòµ½ÐÂÓòÃû
- ÈÃdiv¸¡ÓÚselectÖ®ÉÏ
- ¼¸Æª¹ØÓÚºÐ×ÓÄ£Ð͵ÄÎÄÕ£¬ÈÕºó·½±ã¼ìË÷£º
- Css ÑùʽʹÓþÑé×ܽá
- display:inline-blockµÄÉîÈëÀí½â
- ÈçºÎÔÚÍøÒ³ÖÐǶÈëÌØÊâ×ÖÌå
ÈÈÃÅÐÅÏ¢
- nohup: redirecting stderr to stdou....
- ʹÓÃlog_formatΪNginx·þÎñÆ÷ÉèÖøüÏêϸµÄÈÕÖ¾¸ñʽ
- jquery easyUI--dataGrid-Json
- [Ô´´]·ÂGoogle Reader¡¢ÐÂÀË΢²©¡¢ÌÚѶ΢²©µ....
- ÀûÓÃKeepalived+mysql¹¹½¨¸ß¿ÉÓÃMySQLË«Ö÷×Ô¶....
- Nginx+keepalivedʵÏÖ¸ºÔؾùºâºÍË«»úÈȱ¸¸ß¿ÉÓÃ
- jqueryʵÏÖÒ³Ãæ¼ÓÔؽø¶ÈÌõ
- Rolling cURL: PHP²¢·¢×î¼Ñʵ¼ù
- codeigniter ·ÓÉÖÕ¼«ÓÅ»¯(url rewrite)
- linuxÏÂÉèÖÃsshÎÞÃÜÂëµÇ¼
×î½ü¸üÐÂ
- ´ó±¥ÑÛ¸£ 7¿îÀàÐ͸÷ÒìµÄCSS3ʵÓò˵¥
- div+css¶àä¯ÀÀÆ÷²âÊÔ·½·¨
- cssËõд¸øÍøÕ¾¼ÓËÙ£¬ÆäʵºÜ¶àʱºò¶¼»áÓõ½
- ´¿CSS´òÔìBubbleÆøÅÝÌáʾ¿ò
- CSSʵÏÖͼƬ°´±ÈÀýËõ·Å
- CSS¼¼ÇÉÈÃÄãµÄÍøÕ¾¸üÉÏÒ»²ãÂ¥
- ¹Ì¶¨¸ß¶Èdiv,ËæÄÚÈÝ×Ô¶¯±ä¸ßcss¶¨Òå·½·¨
- web¼æÈݸ÷¸öä¯ÀÀÆ÷×îС¸ß¶ÈµÄд·¨
- CSS£¬Ç³ÎöpositionÖÐRelativeºÍAbsolute
- 12ÌõÔÔò£º±£³ÖHTML´úÂëÕû½à&¹æ·¶
ÆÀÂÛ