{"id":2037,"date":"2022-11-17T13:38:56","date_gmt":"2022-11-17T05:38:56","guid":{"rendered":"http:\/\/www.tra56.com\/?p=2037"},"modified":"2022-11-17T13:38:56","modified_gmt":"2022-11-17T05:38:56","slug":"2037","status":"publish","type":"post","link":"https:\/\/www.tra56.com\/2037.html","title":{"rendered":"php\u5236\u4f5cinstall\u7a0b\u5e8f\u5b89\u88c5\u754c\u9762"},"content":{"rendered":"
\u770b\u5230\u5f88\u591a\u7f51\u7ad9\u7a0b\u5e8f\u5b89\u88c5\u90fd\u662f\u7528install\u9875\u9762\u6765\u5b89\u88c5\uff0c\u524d\u51e0\u5929\u5b66\u4e60\u5236\u4f5c\u4e86php+mysql\u7684\u7559\u8a00\u677f\uff0c\u5176\u4e2d\u7684\u914d\u7f6e\u6587\u4ef6\u90fd\u662f\u624b\u5de5\u6253\u5f00\u914d\u7f6e\u586b\u5199\u7684\uff0c\u4eca\u5929\u6211\u4eec\u7b80\u5355\u7684\u5206\u6790\u4e00\u4e0b\u7f51\u7ad9\u7a0b\u5e8f\u81ea\u52a8\u5b89\u88c5\u7684\u539f\u7406\uff01<\/p>\n
\u5236\u4f5c\u601d\u8def\uff1a<\/p>\n
1\u3001\u521b\u5efa\u586b\u5199\u6570\u636e\u5e93\u670d\u52a1\u5668\u7684\u57fa\u672c\u4fe1\u606f\u8868\u5355;
2\u3001\u5c06\u586b\u5199\u597d\u7684\u6570\u636e\u5199\u5165\u5230\u7f51\u7ad9\u7684\u57fa\u672c\u914d\u7f6e\u6587\u4ef6config.php\u4e2d;
3\u3001\u5220\u9664\u5b89\u88c5\u6587\u4ef6\u3002<\/p>\n
\u5efa\u7acb\u586b\u5199\u8868\u5355\u7684web\u9875\u9762\uff1ainstall.php\u3002\u4ee3\u7801\u5982\u4e0b\uff1a<\/p>\n
<html>\r\n<head>\r\n<title>\u7f51\u7ad9\u5b89\u88c5<\/title>\r\n<\/head>\r\n<body>\r\n <form action="check_install.php" method="POST">\r\n <table>\r\n <tr><td align="right"><font color="Red">*<\/font> \u8f93\u5165\u6570\u636e\u5e93\u670d\u52a1\u5668\u5730\u5740\uff1a<\/td><td><input name="llcc_server" type="text" value="localhost"><\/td><\/tr>\r\n <tr><td align="right"><font color="Red">*<\/font> \u8f93\u5165\u6570\u636e\u5e93\u670d\u52a1\u5668\u7528\u6237\u540d\uff1a<\/td><td><input name="llcc_user_name" type="text" value=""><\/td><\/tr>\r\n <tr><td align="right"><font color="Red">*<\/font> \u8f93\u5165\u6570\u636e\u5e93\u670d\u52a1\u5668\u5bc6\u7801\uff1a<\/td><td><input name="llcc_user_pass" type="text" value=""><\/td><\/tr>\r\n <tr><td align="right"><font color="Red">*<\/font> \u8f93\u5165\u6570\u636e\u5e93\u540d\u79f0\uff1a<\/td><td><input name="llcc_data_name" type="text" value=""> <\/td><\/tr>\r\n <tr><td><input type="submit" name="install" value="\u63d0\u4ea4"><\/td><\/tr>\r\n <\/table>\r\n <\/form>\r\n<\/body>\r\n<\/html><\/pre>\n\u65b0\u5efa\u4e00\u4e2acheck_install.php\u6587\u4ef6\uff0c\u590d\u5236\u4ee5\u4e0b\u4ee3\u7801\uff01<\/span><\/p>\n
<?php\r\n\/\/\u83b7\u53d6\u63d0\u4ea4\u7684\u6570\u636e\u5e93\u503c\r\n$llcc_server=$_POST['llcc_server'];\r\n$llcc_user_name=$_POST['llcc_user_name'];\r\n$llcc_user_pass=$_POST['llcc_user_pass'];\r\n$llcc_data_name=$_POST['llcc_data_name'];\r\n\/\/\u6253\u5f00\u6570\u636e\u5e93\u914d\u7f6e\u6587\u4ef6\r\n$fp=fopen("..\/config.php",'w');\r\nif (!$fp) {\r\necho "sorry,try again!";\r\n}\r\n\/\/\u5199\u5165\u6587\u4ef6\u5185\u5bb9\r\n\r\n$outconfig="<?php\\n";\r\n$outconfig.='$server=';\r\n$outconfig.="".$llcc_server.";\/\/\u6570\u636e\u5e93\u6240\u5728IP\uff0c\u5982\u679c\u662f\u672c\u5730\uff0c\u9ed8\u8ba4localhost\\n";\r\n$outconfig.='$server_name=';\r\n$outconfig.="".$llcc_user_name.";\/\/\u8fde\u63a5\u6570\u636e\u5e93\u7528\u6237\u540d\uff0c\u4e00\u822c\u4e3aroot\\n";\r\n$outconfig.='$server_pass=';\r\n$outconfig.="".$llcc_user_pass.";\/\/\u8fde\u63a5\u6570\u636e\u5e93\u5bc6\u7801\u3002\\n";\r\n$outconfig.='$server_data=';\r\n$outconfig.="".$llcc_data_name.";\/\/\u6570\u636e\u5e93\u540d\\n";\r\n$outconfig.="?>";\r\n$fw=fwrite($fp,$outconfig);\r\nif ($fw) {echo "<br><br><br><center>\u5b89\u88c5\u5b8c\u6210\uff01\u8bf7\u624b\u52a8\u5220\u9664\u76ee\u5f55\u4e0binstall\u6587\u4ef6\u5939<br><a href="'..\/'&hu;\v8ge4\v56ef\v9996\v9875μ\/b&hu;μ\/dfoufs&hu;&rvpu;;}\s\o?&hu;<\/qsf">\n\u5982\u679c\u770b\u8fc7php\u57fa\u7840\u6559\u7a0b\u7684\uff0c\u90a3\u4e48\u4e0a\u9762\u7684\u5185\u5bb9\u5e94\u8be5\u6beb\u65e0\u538b\u529b\uff01<\/span><\/span><\/p>\n","protected":false},"excerpt":{"rendered":"
\u770b\u5230\u5f88\u591a\u7f51\u7ad9\u7a0b\u5e8f\u5b89\u88c5\u90fd\u662f\u7528install\u9875\u9762\u6765\u5b89\u88c5\uff0c\u524d\u51e0\u5929\u5b66\u4e60\u5236\u4f5c\u4e86php+mysql\u7684\u7559\u8a00\u677f\uff0c\u5176\u4e2d\u7684\u914d\u7f6e\u6587\u4ef6 […]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[10,92],"tags":[],"class_list":["post-2037","post","type-post","status-publish","format-standard","hentry","category-php","category-phpcode"],"_links":{"self":[{"href":"https:\/\/www.tra56.com\/wp-json\/wp\/v2\/posts\/2037"}],"collection":[{"href":"https:\/\/www.tra56.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.tra56.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.tra56.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.tra56.com\/wp-json\/wp\/v2\/comments?post=2037"}],"version-history":[{"count":1,"href":"https:\/\/www.tra56.com\/wp-json\/wp\/v2\/posts\/2037\/revisions"}],"predecessor-version":[{"id":2038,"href":"https:\/\/www.tra56.com\/wp-json\/wp\/v2\/posts\/2037\/revisions\/2038"}],"wp:attachment":[{"href":"https:\/\/www.tra56.com\/wp-json\/wp\/v2\/media?parent=2037"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.tra56.com\/wp-json\/wp\/v2\/categories?post=2037"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.tra56.com\/wp-json\/wp\/v2\/tags?post=2037"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}