{"id":24,"date":"2007-05-21T00:17:36","date_gmt":"2007-05-21T04:17:36","guid":{"rendered":"http:\/\/prglab.com\/blog\/?page_id=24"},"modified":"2007-08-25T14:05:30","modified_gmt":"2007-08-25T18:05:30","slug":"js-mis","status":"publish","type":"page","link":"https:\/\/www.prglab.com\/blog\/js-tutorial\/js-mis","title":{"rendered":"JS\u57fa\u7840\u8981\u70b9"},"content":{"rendered":"<p>\u6700\u540e\u662fJS\u7f16\u5199\u4e2d\u7684\u51e0\u4e2a\u8981\u70b9\u3002<\/p>\n<p>&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;<br \/>\n<strong>JavaScript \u533a\u5206\u5927\u5c0f\u5199<\/strong><\/p>\n<p>\u547d\u540d\u4e3a&#8221;myfunction&#8221;\u7684\u51fd\u6570\u4e0e\u547d\u540d\u4e3a &#8220;myFunction&#8221; \u7684\u51fd\u6570\u662f\u4e0d\u540c\u7684\uff0c\u540c\u6837\u540d\u4e3a&#8221;myVar&#8221;\u7684\u53d8\u91cf\u548c\u540d\u4e3a&#8221;myvar&#8221;\u4e5f\u662f\u4e0d\u540c\u7684\u3002<\/p>\n<p>JavaScript\u662f\u533a\u5206\u5927\u5c0f\u5199\u7684\uff0c\u56e0\u6b64\u5728\u4f60\u5b9a\u4e49\u548c\u8c03\u7528\u53d8\u91cf\uff0c\u5bf9\u8c61\u548c\u51fd\u6570\u7684\u65f6\u5019\u4e00\u5b9a\u8981\u6ce8\u610f\u5927\u5c0f\u5199\u7684\u4f7f\u7528\u3002<\/p>\n<p>&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-<br \/>\n<strong>\u7a7a\u683c<\/strong><\/p>\n<p>JavaScript\u4f1a\u5ffd\u7565\u591a\u4f59\u7684\u7a7a\u683c\uff0c\u8fd9\u5c31\u610f\u5473\u7740\u4f60\u53ef\u4ee5\u5728\u4f60\u7684\u811a\u672c\u4e2d\u4f7f\u7528\u7a7a\u683c\u6765\u4f7f\u5b83\u66f4\u5bb9\u6613\u8bfb\u3002\u4ee5\u4e0b\u4e24\u884c\u4ee3\u7801\u5728JaveScript\u770b\u6765\u662f\u7b49\u540c\u7684\uff1a<\/p>\n<table align=\"center\" border=\"0\" cellpadding=\"3\" cellspacing=\"1\" width=\"96%\">\n<tr>\n<td class=\"quote\">name=&#8221;Hege&#8221;<br \/>\nname = &#8220;Hege&#8221;<\/td>\n<\/tr>\n<\/table>\n<p>&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;<br \/>\n<strong>\u6253\u65ad\u4ee3\u7801\u884c<\/strong><\/p>\n<p>\u4f60\u53ef\u4ee5\u5728\u4e00\u884c\u4ee3\u7801\u7684\u5b57\u7b26\u4e32\u4e2d\u4f7f\u7528\u53cd\u659c\u6760\u6765\u6253\u65ad\u8fd9\u884c\u4ee3\u7801\u3002\u5982\u4e0b\u4f8b\u6240\u793a\uff1a<\/p>\n<table align=\"center\" border=\"0\" cellpadding=\"3\" cellspacing=\"1\" width=\"96%\">\n<tr>\n<td class=\"quote\">document.write(&#8220;Hello \\<br \/>\nWorld!&#8221;)<\/td>\n<\/tr>\n<\/table>\n<p>\u4f46\u662f\uff0c\u4f60\u4e0d\u80fd\u50cf\u8fd9\u6837\u6253\u65ad\u4e00\u884c\u4ee3\u7801\uff1a<\/p>\n<table align=\"center\" border=\"0\" cellpadding=\"3\" cellspacing=\"1\" width=\"96%\">\n<tr>\n<td class=\"quote\">document.write \\<br \/>\n(&#8220;Hello World!&#8221;)<\/td>\n<\/tr>\n<\/table>\n<p>&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;<br \/>\n<strong>\u6ce8\u91ca<\/strong><\/p>\n<p>JS\u811a\u672c\u7528\u53cc\u659c\u6760 \/\/\u6765\u6ce8\u91ca\u4e00\u884c:<\/p>\n<table align=\"center\" border=\"0\" cellpadding=\"3\" cellspacing=\"1\" width=\"96%\">\n<tr>\n<td class=\"quote\"><span style=\"color: green\">\/\/this is a comment<\/span><br \/>\ndocument.write(&#8220;Hello World!&#8221;)<\/td>\n<\/tr>\n<\/table>\n<p>\u6216\u4f7f\u7528 \/* \u548c *\/ \u6765\u6ce8\u91ca\u4e00\u6bb5:<\/p>\n<table align=\"center\" border=\"0\" cellpadding=\"3\" cellspacing=\"1\" width=\"96%\">\n<tr>\n<td class=\"quote\"><span style=\"color: green\">\/* This is a comment<br \/>\nblock. It contains<br \/>\nseveral lines *\/<\/span><br \/>\ndocument.write(&#8220;Hello World!&#8221;)<\/td>\n<\/tr>\n<\/table>\n","protected":false},"excerpt":{"rendered":"<p>\u6700\u540e\u662fJS\u7f16\u5199\u4e2d\u7684\u51e0\u4e2a\u8981\u70b9\u3002 &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211; JavaScript \u533a\u5206\u5927\u5c0f\u5199 \u547d\u540d\u4e3a&#8221;myfunction&#8221;\u7684\u51fd\u6570\u4e0e\u547d\u540d\u4e3a &#8220;myFunction&#8221; \u7684\u51fd\u6570\u662f\u4e0d\u540c\u7684\uff0c\u540c\u6837\u540d\u4e3a&#8221;myVar&#8221;\u7684\u53d8\u91cf\u548c\u540d\u4e3a&#8221;myvar&#8221;\u4e5f\u662f\u4e0d\u540c\u7684\u3002 JavaScript\u662f\u533a\u5206\u5927\u5c0f\u5199\u7684\uff0c\u56e0\u6b64\u5728\u4f60\u5b9a\u4e49\u548c\u8c03\u7528\u53d8\u91cf\uff0c\u5bf9\u8c61\u548c\u51fd\u6570\u7684\u65f6\u5019\u4e00\u5b9a\u8981\u6ce8\u610f\u5927\u5c0f\u5199\u7684\u4f7f\u7528\u3002 &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;- \u7a7a\u683c JavaScript\u4f1a\u5ffd\u7565\u591a\u4f59\u7684\u7a7a\u683c\uff0c\u8fd9\u5c31\u610f\u5473\u7740\u4f60\u53ef\u4ee5\u5728\u4f60\u7684\u811a\u672c\u4e2d\u4f7f\u7528\u7a7a\u683c\u6765\u4f7f\u5b83\u66f4\u5bb9\u6613\u8bfb\u3002\u4ee5\u4e0b\u4e24\u884c\u4ee3\u7801\u5728JaveScript\u770b\u6765\u662f\u7b49\u540c\u7684\uff1a name=&#8221;Hege&#8221; name = &#8220;Hege&#8221; &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211; \u6253\u65ad\u4ee3\u7801\u884c \u4f60\u53ef\u4ee5\u5728\u4e00\u884c\u4ee3\u7801\u7684\u5b57\u7b26\u4e32\u4e2d\u4f7f\u7528\u53cd\u659c\u6760\u6765\u6253\u65ad\u8fd9\u884c\u4ee3\u7801\u3002\u5982\u4e0b\u4f8b\u6240\u793a\uff1a document.write(&#8220;Hello \\ World!&#8221;) \u4f46\u662f\uff0c\u4f60\u4e0d\u80fd\u50cf\u8fd9\u6837\u6253\u65ad\u4e00\u884c\u4ee3\u7801\uff1a document.write \\ (&#8220;Hello World!&#8221;) &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212; \u6ce8\u91ca JS\u811a\u672c\u7528\u53cc\u659c\u6760 \/\/\u6765\u6ce8\u91ca\u4e00\u884c: \/\/this is a comment document.write(&#8220;Hello World!&#8221;) \u6216\u4f7f\u7528 \/* \u548c *\/ \u6765\u6ce8\u91ca\u4e00\u6bb5: \/* This is a comment block. It contains several lines *\/ document.write(&#8220;Hello World!&#8221;)<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":3,"menu_order":17,"comment_status":"open","ping_status":"open","template":"","meta":[],"_links":{"self":[{"href":"https:\/\/www.prglab.com\/blog\/wp-json\/wp\/v2\/pages\/24"}],"collection":[{"href":"https:\/\/www.prglab.com\/blog\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.prglab.com\/blog\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.prglab.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.prglab.com\/blog\/wp-json\/wp\/v2\/comments?post=24"}],"version-history":[{"count":0,"href":"https:\/\/www.prglab.com\/blog\/wp-json\/wp\/v2\/pages\/24\/revisions"}],"up":[{"embeddable":true,"href":"https:\/\/www.prglab.com\/blog\/wp-json\/wp\/v2\/pages\/3"}],"wp:attachment":[{"href":"https:\/\/www.prglab.com\/blog\/wp-json\/wp\/v2\/media?parent=24"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}