{"id":769,"date":"2011-11-18T00:09:37","date_gmt":"2011-11-17T16:09:37","guid":{"rendered":""},"modified":"2014-03-11T22:40:48","modified_gmt":"2014-03-11T14:40:48","slug":"%e6%80%8e%e4%b9%88%e7%94%a8asp%e5%88%b6%e4%bd%9c%e5%ae%89%e8%a3%85%e5%90%91%e5%af%bc%e9%a1%b5%e9%9d%a2","status":"publish","type":"post","link":"http:\/\/www.xiaoyebailong.com\/index.php\/2011\/11\/18\/769.htm","title":{"rendered":"\u600e\u4e48\u7528ASP\u5236\u4f5c\u5b89\u88c5\u5411\u5bfc\u9875\u9762"},"content":{"rendered":"<p>\u6211\u4eec\u4ece\u7f51\u4e0a\u4e0b\u8f7d\u7684\u4e00\u4e9b\u7a0b\u5e8f\u5982\u8bba\u575b\uff0c\u5728\u5b89\u88c5\u7684\u65f6\u5019\u6709\u7c7b\u4f3c\u8f6f\u4ef6\u4e00\u6837\u7684\u5b89\u88c5\u5411\u5bfc\uff0c\u8fd9\u6837\u65b9\u4fbf\u4e86\u7528\u6237\u7684\u5b89\u88c5\uff0c\u8fd9\u4e2a\u529f\u80fd\u8981\u5982\u4f55\u5b9e\u73b0\u5462\uff1f<\/p>\n<p>\u6211\u4eec\u9762\u4e34\u7684\u4e3b\u8981\u95ee\u9898\u5728\u4e8e\uff1a<\/p>\n<p>1\u3002\u754c\u9762\u548c\u4e00\u4e2aWindows Wizard\u5b8c\u5168\u4e00\u6837\uff0c\u6709Next\u548cBack\u6309\u94ae<br \/>\n2\u3002\u7528\u6237\u53ef\u4ee5\u4f7f\u7528Back\u6309\u94ae\u56de\u5230\u4ee5\u524d\u7684\u4efb\u4f55\u4e00\u6b65\uff0c\u5e76\u4e14\u80fd\u591f\u6539\u53d8\u4ee5\u524d\u4efb\u4f55\u4e00\u6b65\u4e2d\u5df2\u7ecf\u9009\u62e9\u7684\u5185\u5bb9<br \/>\n3\u3002Form\u5fc5\u987b\u8bb0\u4f4f\u6240\u6709\u586b\u5165\u7684\u5185\u5bb9<br \/>\n4\u3002\u4e0d\u80fd\u591f\u4f7f\u7528\u6570\u636e\u5e93<br \/>\n5\u3002\u4e0d\u80fd\u591f\u4f7f\u7528sessions\uff0c\u9632\u6b62\u5982\u679cSessiosn\u5931\u6548\u540e\u7528\u6237\u7684\u6240\u6709\u8f93\u5165\u4e22\u5931\uff0c\u4e0d\u5e78\u7684\u662f\uff0c\u4e5f\u4e0d\u80fd\u591f\u4f7f\u7528cookie<br \/>\n\u56e0\u4e3a\u5f88\u591a\u62e5\u62a4\u7ecf\u5e38\u5173\u6389\u6d4f\u89c8\u5668\u7684Cookie\u9009\u9879\u3002<br \/>\n6\u3002\u53ef\u79fb\u690d\u6027\u8981\u597d\uff0c\u56e0\u4e3a\u5b83\u8981\u9002\u5e94\u5b89\u88c5\u6b65\u6570\u4e0d\u540c\u65f6\u7684\u60c5\u51b5<\/p>\n<p>&nbsp; \u89e3\u51b3\u65b9\u6848\uff1a<br \/>\n1\u3002\u4f7f\u7528hidden\u53d8\u91cf\u4f20\u9012\u53c2\u6570<br \/>\n2\u3002\u4f7f\u7528POST\u65b9\u5f0f\uff0c\u4e0d\u4f7f\u7528GET\u65b9\u5f0f\uff0c\u56e0\u4e3a\u8fd9\u79cd\u65b9\u5f0f\u53d7\u957f\u5ea6\u9650\u5236<br \/>\n3\u3002\u6bcf\u4e00\u4e2a\u9875\u9762\u90fd\u5fc5\u987b\u6709\u4e00\u4e2a\u7528\u6765\u8bfb\u53d6\u63d0\u4ea4\u503c\u7684\u51fd\u6570<br \/>\n4\u3002\u6bcf\u4e00\u4e2a\u9875\u9762\uff08\u9664\u4e86\u7b2c\u4e00\u4e2a\u9875\u9762\u5916\uff09\u90fd\u5fc5\u987b\u8981\u6709\u4e00\u4e2ahidden form \u6765\u5411\u524d\u4e00\u9875\u4f20\u9012\u53c2\u6570<\/p>\n<p>\n&nbsp; \u5982\u679c\u5728\u4f60\u7684\u9875\u9762\u4e2d\u4f7f\u7528\u4e86Checkboxes\u6216\u5219\u4f7f\u7528\u4e86radio buttons\uff0c\u8bf7\u4f7f\u7528\u4ee5\u4e0b\u4ee3\u7801\u8bfb\u6570\u503c\uff1a<br \/>\n&nbsp;<\/p>\n<p>&lt;% For Each Item in Request.Form<br \/>\nIf Request.Form(Item).Count Then<br \/>\nFor intLoop = 1 to Request.Form(Item).Count<br \/>\nResponse.Write &quot;Item = &quot; &amp; Item &amp; &quot; Index = &quot; &amp; intLoop &amp; &quot;&lt;BR&gt;&quot;<br \/>\nNext<br \/>\nElse <br \/>\nResponse.Write &quot;Item = &quot; &amp; Item &amp; &quot;&lt;BR&gt;&quot;<br \/>\nEnd If<br \/>\nNext<br \/>\n%&gt;<\/p>\n<p>&nbsp; \u5728\u8bbe\u8ba1\u662f\uff0c\u5bf9checkboxes\u548cradio\u91c7\u7528\u4e86\u7279\u6b8a\u7684\u5904\u7406\u65b9\u6cd5\uff1a<br \/>\n1\u3002\u53ea\u6709\u6700\u65b0\u7684\u6570\u503c\u624d\u88ab\u8003\u8651\u4f7f\u7528\u8fd9\u4e24\u79cd\u65b9\u5f0f\u4fdd\u5b58<br \/>\n2\u3002\u7528\u6237\u53ef\u4ee5\u4f7f\u7528Back\u6765\u6539\u53d8\u524d\u9762\u8f93\u5165\u7684\u6570\u503c\uff0c\u4f46\u5fc5\u987b\u8981\u4f7f\u7528Next\u63d0\u4ea4\u540e\u624d\u80fd\u591f\u751f\u6548<br \/>\n3\u3002\u9875\u9762\u5fc5\u987b\u8981\u80fd\u591f\u5e94\u4ed8\u4e00\u4e2a\u9875\u9762\u6709\u591a\u4e2acontrols\u7684\u60c5\u51b5<\/p>\n<p>&nbsp; \u5177\u4f53\u5b9e\u73b0\u65b9\u6cd5\uff1a<br \/>\n\u7b2cN\u4e2a\u9875\u9762\u5e94\u8be5\u6709\uff1a<br \/>\n1\u3002\u7b2c\u4e00\u4e2aform:\u5b83\u7684ACTION= page(N+1).asp\u548c\u5b83\u5e95\u90e8\u5fc5\u987b\u6709Next\u6309\u94ae<br \/>\n2\u3002\u7b2c\u4e8c\u4e2aform:\u5b83\u7684ACTION= page(N-1).asp\u548cBack\u6309\u94ae<br \/>\n3\u3002\u53d8\u91cf\u547d\u540d\u89c4\u5219\uff1a\u4e3e\u4f8b\uff1aN_&lt;page no&gt; \u540e\u7f00\u662f\u63a7\u4ef6\u7c7b\u578b. &lt;INPUT TYPE = RADIO NAME = RADIO_P2&gt; <br \/>\n\u662f\u8868\u793a\u7b2c\u4e8c\u9875\u7684\u4e00\u4e2aname\u662fradio\u7684\u4e1c\u897f<br \/>\n4\u3002\u4e00\u4e2a\u7528\u6765\u8bfb\u53d6\u63d0\u4ea4\u7684\u51fd\u6570<\/p>\n<p>&nbsp; \u9875\u9762\u6839\u636e\u4e00\u4e2a\u5faa\u73af\u6765\u5224\u65ad\u5f53\u524d\u7684\u63a7\u4ef6\u662f\u5c5e\u4e8e\u54ea\u4e00\u9875\u7684\u3002<br \/>\n\u4ee3\u7801\u5982\u4e0b\uff1a<br \/>\n&nbsp;<\/p>\n<p>&lt;<a href=\"mailto:%@LANGUAGE=&quot;VBSCRipT\">%@LANGUAGE=&quot;VBSCRipT<\/a> %&gt;<br \/>\n&lt;HTML&gt;<br \/>\n&lt;HEAD&gt;<br \/>\n&lt;\/HEAD&gt;<br \/>\n&lt;BODY&gt;<br \/>\n&lt;!&#8211; NEXT\u6309\u94ae\u6a21\u5757\u7f16\u7a0b\u5f00\u59cb &#8211;&gt;<br \/>\n&lt;FORM ACTION=&quot;page03.asp&quot; METHOD=&quot;POST&quot; &gt;<br \/>\n&lt;!&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-&gt;<br \/>\n&lt;!&#8211;\u8bfb\u5165\u51fd\u6570\u5f00\u59cb &#8211;&gt;<br \/>\n&lt;!&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-&gt;<br \/>\n&lt;%<br \/>\npageno = &quot;_P2&quot; <br \/>\nFor Each Item in Request.Form <br \/>\nWhichPage = InStr(1,CStr(Item), pageno,1) <br \/>\nIf ((Request.Form(Item).Count) AND (WhichPage = 0)) Then<br \/>\nstrCount = Request.Form(Item).Count <br \/>\nstrItem = Request.Form(Item)(strCount)<br \/>\nResponse.Write &quot;&lt;INPUT TYPE=&quot;&quot;HIDDEN&quot;&quot; NAME=&quot;&quot;&quot; &amp; Item &amp; &quot;&quot;&quot; VALUE=&quot;&quot;&quot; &amp; strItem &amp; &quot;&quot;&quot;&gt;&quot; &amp;VbCrLf<br \/>\nElseIf (NOT(Request.Form(Item).Count) AND (WhichPage = 0)) Then <br \/>\nResponse.Write &quot;&lt;INPUT TYPE=&quot;&quot;HIDDEN&quot;&quot; NAME=&quot;&quot;&quot; &amp; Item &amp; &quot;&quot;&quot; VALUE=&quot;&quot;&quot; &amp; strItem &amp; &quot;&quot;&quot;&gt;&quot; &amp;VbCrLf<br \/>\nEnd If<br \/>\nNext<br \/>\n%&gt;<br \/>\n&lt;!&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&gt; <br \/>\n&lt;1&#8211; \u8bfb\u5165\u51fd\u6570\u7ed3\u675f &#8211;&gt;<br \/>\n&lt;!&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&gt;<\/p>\n<p>&lt;!&#8211; #include file = &quot;Check_UnCheck.txt&quot; &#8211;&gt; <br \/>\n&lt;%<br \/>\nFunction Check_UnCheck(ctrlName, ctrlValue)<br \/>\nDim ctrlName_in<br \/>\nDim ctrlValue_in<br \/>\nDim ctrlValue_actual<br \/>\nDim outStr<\/p>\n<p>ctrlValue_in =&quot;&quot;<br \/>\nctrlName_in = &quot;&quot;<br \/>\nctrlValue_actual = &quot;&quot;<br \/>\noutStr = &quot;&quot;<br \/>\nctrlName_in = ctrlName_in &amp; ctrlName<br \/>\nctrlValue_in = ctrlValue_in &amp; ctrlValue<\/p>\n<p>If Request.Form(ctrlName_in).Count Then<br \/>\nstrCount = Request.Form(ctrlName_in).Count<br \/>\nctrlValue_actual = Request.Form(ctrlName_in)(strCount)<br \/>\nIf ctrlValue_actual = ctrlValue_in Then<br \/>\noutStr = &quot;CHECKED&quot;<br \/>\nEnd If<br \/>\nElse <br \/>\nctrlValue_actual = Request.Form(ctrlName_in)<br \/>\nIf ctrlValue_actual = ctrlValue_in Then<br \/>\noutStr = &quot;CHECKED&quot;<br \/>\nEnd If<br \/>\nEnd If<br \/>\nCheck_UnCheck = outStr <br \/>\nEnd Function <br \/>\n%&gt;<\/p>\n<p>&lt;!&#8211; Back\u6309\u94ae\u6a21\u5757\u5f00\u59cb &#8211;&gt;<\/p>\n<p>&lt;%<br \/>\nstrItem1 = &quot;&quot;<br \/>\nstrItem1a = &quot;&quot;<br \/>\nFor Each Item1 in Request.Form<br \/>\nIf Request.Form(Item1).Count Then<br \/>\nstrCount1 = Request.Form(Item1).Count <br \/>\nstrItem1 = Request.Form(Item1)(strCount1)<br \/>\nResponse.Write &quot;&lt;INPUT TYPE=&quot;&quot;HIDDEN&quot;&quot; NAME=&quot;&quot;&quot; &amp; Item1 &amp; &quot;&quot;&quot; VALUE=&quot;&quot;&quot; &amp; strItem1 &amp; &quot;&quot;&quot;&gt;&quot; &amp;VbCrLf<br \/>\nstrCount1 = &quot;&quot;<br \/>\nstrItem1 = &quot;&quot;<br \/>\nElse<br \/>\nstrItem1a = Request.Form(Item1)<br \/>\nResponse.Write &quot;&lt;INPUT TYPE=&quot;&quot;HIDDEN&quot;&quot; NAME=&quot;&quot;&quot; &amp; Item1 &amp; &quot;&quot;&quot; VALUE=&quot;&quot;&quot; &amp; strItem1a &amp; &quot;&quot;&quot;&gt;&quot; &amp;VbCrLf<br \/>\nEnd If<br \/>\nNext<\/p>\n<p>strItem1 = &quot;&quot;<br \/>\nstrItem1a = &quot;&quot;<br \/>\n%&gt;<br \/>\n&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u6211\u4eec\u4ece\u7f51\u4e0a\u4e0b\u8f7d\u7684\u4e00\u4e9b\u7a0b\u5e8f\u5982\u8bba\u575b\uff0c\u5728\u5b89\u88c5\u7684\u65f6\u5019\u6709\u7c7b\u4f3c\u8f6f\u4ef6\u4e00\u6837\u7684\u5b89\u88c5\u5411\u5bfc\uff0c\u8fd9\u6837\u65b9\u4fbf\u4e86\u7528\u6237\u7684\u5b89\u88c5\uff0c\u8fd9\u4e2a\u529f\u80fd\u8981\u5982\u4f55\u5b9e\u73b0\u5462\uff1f \u6211\u4eec\u9762\u4e34\u7684\u4e3b\u8981\u95ee\u9898\u5728\u4e8e\uff1a 1\u3002\u754c\u9762\u548c\u4e00\u4e2aWindows Wizard\u5b8c\u5168\u4e00\u6837\uff0c\u6709Next\u548cBack\u6309\u94ae 2\u3002\u7528\u6237\u53ef\u4ee5\u4f7f\u7528Ba&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"topic":[],"class_list":["post-769","post","type-post","status-publish","format-standard","hentry","category-technology"],"_links":{"self":[{"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/posts\/769","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/comments?post=769"}],"version-history":[{"count":1,"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/posts\/769\/revisions"}],"predecessor-version":[{"id":66632,"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/posts\/769\/revisions\/66632"}],"wp:attachment":[{"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/media?parent=769"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/categories?post=769"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/tags?post=769"},{"taxonomy":"topic","embeddable":true,"href":"http:\/\/www.xiaoyebailong.com\/index.php\/wp-json\/wp\/v2\/topic?post=769"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}