{"id":128,"date":"2006-07-20T15:26:54","date_gmt":"2006-07-20T07:26:54","guid":{"rendered":"http:\/\/twycf.com\/wordpress\/archives\/128"},"modified":"2006-07-23T15:57:48","modified_gmt":"2006-07-23T07:57:48","slug":"xoops-%e5%88%86%e9%a1%9e%e5%95%9f%e7%94%a8","status":"publish","type":"post","link":"https:\/\/twycf.com\/?p=128","title":{"rendered":"Xoops \u5206\u985e\u555f\u7528"},"content":{"rendered":"<p>\u9019\u5e7e\u500b\u6708\u63a5\u5230\u4e00\u500b\u4f7f\u7528 Xoops \u70ba\u6838\u5fc3\u7684\u7db2\u9801\u958b\u767c\u5c08\u6848\uff0c\u624d\u958b\u59cb\u77ad\u89e3 Xoops \u7684\u65b9\u4fbf\u8207\u6613\u7528\uff0c\u4f46\u4e5f\u77ad\u89e3\u5230Xoops \u7684\u7f3a\u9ede\uff0c\u4ee5\u53ca\u958b\u767c\u6642\u6240\u9047\u5230\u7684\u554f\u984c\u3002<br \/>\n\u5f9e\u5927\u5206\u985e\u4f86\u8aaa\uff0cXoops \u6838\u5fc3\u5305\u542b\u4e86\u4e0b\u8ff0\u529f\u80fd<!--more--><br \/>\n<coolcode linenum=\"off\">XoopsSecurity:\u5b89\u5168\u6027\u6aa2\u67e5\uff0c\u6bd4\u5982HTTP REFERER\u3001security token\u3001\u6aa2\u67e5Global\u8b8a\u6578\u3001\u963b\u64cb badip<br \/>\nXoopsErrorHandler:\u932f\u8aa4\u7ba1\u7406\uff0c\u7a0b\u5f0f\u4e2d\u82e5\u767c\u751f\u932f\u8aa4\uff0c\u53ef\u4ea4\u7531 ErrorHandler\u7522\u751f\u76f8\u95dc\u8a0a\u606f\uff0c\u907f\u514d\u6d29\u6f0f\u7cfb\u7d71\u8a2d\u5b9a<br \/>\nXoopsLogger:\u8a0a\u606f\u8a18\u9304\uff0c\u53ef\u4ee5\u5c07 PHP\u3001Smarty\u3001Mysql \u57f7\u884c\u904e\u7a0b(\u7d50\u679c)\u5373\u6642\u986f\u793a\uff0c\u65b9\u4fbf\u5075\u932f<br \/>\nCriteria:\u8cc7\u6599\u76f8\u5bb9\u57fa\u6e96\uff0c\u70ba\u4e86\u8b93Xoops\u652f\u63f4 LDAP\u3001Mysql \u7684\u4e00\u500b\u865b\u64ec\u985e\u5225<br \/>\nMyTextSanitizer:\u6587\u5b57\u7ba1\u7406\uff0c\u63db\u52a9\u8655\u7406\u8b8a\u6578\u4e2d\u5b57\u5143\u7684\u8f49\u63db(\u5305\u542bSQL Injection)\uff0c\u9810\u89bd\u756b\u9762\uff0c\u53d6\u4ee3&#8221;\u5b57\u5143\u904e\u6ffe\u9078\u9805&#8221;\u8a2d\u5b9a\u88e1\u7684\u4e0d\u7576\u5b57\u5143\uff0c[Code]\u5340\u584a\u8f38\u51fa<br \/>\nXoopsDatabaseFactory:\u8cc7\u6599\u5eab\u57fa\u672c\u985e\u5225\uff0c\u53ea\u8ca0\u8cac\u53d6\u5f97\u8cc7\u6599\u5eab\u7a2e\u985e(\u4e26\u8f09\u5165\u76f8\u5c0d\u7684\u8cc7\u6599\u5eab\u985e\u5225)\u53ca\u9023\u7dda\u90e8\u4efd<br \/>\nXoopsDatabase:\u8cc7\u6599\u5eab\u865b\u64ec\u985e\u5225\uff0c\u53ea\u8ca0\u8cac\u8a18\u9304SQL\u6307\u4ee4\u53ca\u8a2d\u5b9a(\u53d6\u5f97)Xoops Prefix.<br \/>\nXoopsMySQLDatabaseSafe:\u7e7c\u627f\u81eaXoopsMySQLDatabase\uff0c\u6b64\u985e\u5225\u53ef\u4ee5\u57f7\u884cSelect,Insert,Delete,Drop&#8230;\u6240\u6709\u7684SQL\u8a9e\u6cd5<br \/>\nXoopsMySQLDatabaseProxy:\u7e7c\u627f\u81eaXoopsMySQLDatabase\uff0c\u6b64\u985e\u5225\u53ea\u5141\u8a31 Select \u8a9e\u6cd5<br \/>\nXoopsMySQLDatabase:\u7e7c\u627f\u81eaXoopsDatabase\uff0c\u6240\u6709 Mysql \u529f\u80fd\u90fd\u5728\u6b64\u985e\u5225\u88e1\u5be6\u4f5c<br \/>\nXoopsTpl:\u7e7c\u627f\u81eaSmarty\uff0c\u6a23\u7248\u5f15\u64ce<br \/>\nXoopsTree:\u6a39\u72c0\u9078\u55ae\u985e\u5225\uff0c\u7c21\u55ae\u597d\u7528\u7684\u6a39\u72c0\u9078\u55ae\u7522\u751f\uff0c\u7ba1\u7406\u985e\u5225<br \/>\nXoopsModule:\u6a21\u7d44\u57fa\u672c\u985e\u5225\uff0c\u900f\u904e\u9019\u500b\u985e\u5225\u5c0d\u6a21\u7d44\u5b89\u5168(\u66f4\u65b0)\u3001\u521d\u59cb\u5316\u3001\u8b80\u53d6\u6a21\u7d44\u8cc7\u6599\u3001\u6b0a\u9650\u6838\u5c0d(\u7ba1\u7406)\u3001\u8f09\u5165\u76f8\u5c0d\u7684\u8a9e\u7cfb\u3001\u6a23\u7248(\u5340\u584a)\u7ba1\u7406<br \/>\nXoopsMemberHandler\u3001XoopsUser\u3001XoopsGroup:\u6703\u54e1\u7ba1\u7406\uff0c\u7fa4\u7d44,\u4f7f\u7528\u8005,Guest \u6b0a\u9650\u7ba1\u7406<br \/>\nXoopsSessionHandler:Session \u7ba1\u7406<br \/>\nXoopsTplsetHandler:\u6a23\u7248&#8221;\u7d44&#8221;\u7ba1\u7406<br \/>\nXoopsTplfileHandler:\u6a23\u7248&#8221;\u6a94\u6848&#8221;\u7ba1\u7406<\/coolcode>\u4e0a\u8ff0\u53ea\u662f\u4e00\u500b\u5927\u6982\u7684\u5206\u6790\uff0c\u4e26\u6c92\u6709\u628a\u6240\u6709\u7684\u6a21\u7d44\u90fd\u5217\u51fa\u4f86\uff0c\u6bd4\u5982\u5f88\u91cd\u8981\u7684 XoopsForm \u4ee5\u53ca\u5176\u884d\u751f\u985e\u5225XoopsSimpleForm\u3001XoopsTableForm\u3001XoopsThemeForm\u3002\u800c\u90e8\u4efd\u8aaa\u660e\u4e5f\u4e0d\u662f\u975e\u5e38\u8a73\u7d30\uff0c\u9019\u4e9b\u90e8\u4efd\u9084\u8981\u6162\u6162\u6574\u7406\u51fa\u4f86<br \/>\n=====<br \/>\n\u63a5\u4e0b\u4f86\u76f4\u63a5\u5207\u5165\u4e3b\u984c\uff0c\u9019\u908a\u5148\u8df3\u904e\u6a21\u7d44\u57fa\u672c\u67b6\u69cb\u3001\u8a2d\u5b9a\uff0c\u5148\u4f86\u8a0e\u8ad6\u7ba1\u7406\u4ecb\u9762\u7684\u7522\u751f\u65b9\u5f0f<br \/>\n<coolcode><br \/>\n        $result = $xoopsDB->query(&#8220;SELECT cid, title FROM &#8220;.$xoopsDB->prefix(&#8220;myconference_main&#8221;).&#8221; ORDER BY title ASC&#8221;) or $eh->show(&#8220;0013&#8221;);<br \/>\n        $conference_select = new XoopsFormSelect(_MD_TITLE, &#8220;cid&#8221;,$cid);<br \/>\n        $conference_select->setExtra(&#8216;onchange=&#8221;this.form.submit();&#8221;&#8216;);<br \/>\n        $conference_select->addOption(0, &#8220;&#8211;\u8acb\u9078\u64c7\u6703\u8b70\u5e74\u5ea6&#8211;&#8220;);<br \/>\n        while (list($cid_v, $title) = $xoopsDB->fetchRow($result) ) {<br \/>\n            $conference_select->addOption($cid_v, $title);<br \/>\n        }<\/p>\n<p>        $editform = new XoopsThemeForm(_MD_EDITSPEECH, &#8220;choicespeechform&#8221;, &#8220;speeches.php&#8221;);<br \/>\n        $editform->addElement($conference_select);<br \/>\n        $editform->display();<\/coolcode><br \/>\n\u9019\u6a23\u5c31\u5b8c\u6210\u4e86\u4e00\u500b\u8868\u55ae\u7684\u8f38\u51fa<br \/>\n<img loading=\"lazy\" decoding=\"async\" src=\"\/wordpress\/wp-content\/uploads\/2006\/07\/form1.PNG\" alt=\"form1.PNG\" title=\"form1.PNG\" align=\"texttop\" width=\"308\" height=\"92\" border=\"0\" \/><br \/>\n1-7\u884c\uff0c\u7522\u751f\u4e00\u500b\tXoopsFormSelect \u7269\u4ef6\uff0c\u4e26\u628a\u8cc7\u6599\u5eab\u4e2d\u67e5\u8a62\u5230\u7684\u6703\u8b70\u5e74\u5ea6\uff0c\u65b0\u589e\u5230\u4e0b\u62c9\u9078\u55ae\u4e2d<br \/>\n9  \u884c\uff0c\u7522\u751f\u4e00\u500b editform(XoopsThemeForm) \u7269\u4ef6\uff0c\u4e26\u628a post \u7d50\u679c\u6307\u5230 speeches.php<br \/>\n10 \u884c\uff0c\u5c07 conference_select \u65b0\u589e\u5230 editform \u4e2d<br \/>\n11 \u884c\uff0c\u547c\u53eb $editform->display() \u7522\u751f\u756b\u9762<\/p>\n<p>Xoops \u4ecb\u9762\u8f38\u51fa\u4f7f\u7528\u4e0a\u76f8\u7576\u7684\u7c21\u6f54\uff0c\u4e5f\u63d0\u4f9b\u4e86\u5f9e\u57fa\u672c\u5230\u9032\u968e\u7684\u8868\u55ae\u5143\u4ef6\uff0c\u4f8b\u5982\uff0cInput\u3001TextArea(DhtmlTextArea)\u3001Button\u3001checkbox\u3001file\u3001hidden\u3001label\u3001password\u3001radio(radioYN)\u3001select(\u570b\u5bb6,\u7fa4\u7d44,\u8a9e\u8a00,\u5217\u8868,\u6642\u5340,\u4e3b\u984c,\u7528\u6236)\u3001datetime\u3001editor(WYSIWYG)\u3001elementtray\u3001tree&#8230;\u7b49\u7b49<br \/>\n\u958b\u767c\u4eba\u54e1\u4e0d\u7528\u518d\u81ea\u884c\u7522\u751f HTML \u6a23\u7248\u624d\u80fd\u958b\u767c\uff0c\u4e5f\u4e0d\u7528\u7b49\u7f8e\u5de5\u7684\u7ba1\u7406\u4ecb\u9762\u6a23\u7248\u3002\u4f46\u76f8\u5c0d\u7684\u7f3a\u9ede\u662f\u4ecb\u9762\u55ae\u8abf\uff0c\u7279\u6b8a\u9700\u6c42\u4e0d\u6613\u505a\u5230\u3002\u9019\u4e9b\u7279\u6b8a\u9700\u6c42\u7684\u7ba1\u7406\u4ecb\u9762\uff0c\u6368\u68c4\u4e86  Xoops \u672c\u8eab\u63d0\u4f9b\u7684\u8868\u55ae\u5143\u4ef6\uff0c\u800c\u9078\u64c7\u81ea\u884c\u7d44\u5408 HTML \u4f86\u9054\u5230\uff0c\u4f46\u662f\u9019\u6a23\u505a\u7684\u7f3a\u9ede\u662f\u7dad\u8b77\u4e0d\u6613\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u9019\u5e7e\u500b\u6708\u63a5\u5230\u4e00\u500b\u4f7f\u7528 Xoops \u70ba\u6838\u5fc3\u7684\u7db2\u9801\u958b\u767c\u5c08\u6848\uff0c\u624d\u958b\u59cb\u77ad\u89e3 Xoops \u7684\u65b9\u4fbf\u8207\u6613\u7528\uff0c\u4f46\u4e5f\u77ad\u89e3\u5230Xoo [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[15],"tags":[],"class_list":["post-128","post","type-post","status-publish","format-standard","hentry","category-xoops"],"_links":{"self":[{"href":"https:\/\/twycf.com\/index.php?rest_route=\/wp\/v2\/posts\/128","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/twycf.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/twycf.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/twycf.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/twycf.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=128"}],"version-history":[{"count":0,"href":"https:\/\/twycf.com\/index.php?rest_route=\/wp\/v2\/posts\/128\/revisions"}],"wp:attachment":[{"href":"https:\/\/twycf.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=128"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/twycf.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=128"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/twycf.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=128"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}