{"id":3,"date":"2006-11-21T01:08:59","date_gmt":"2006-11-20T17:08:59","guid":{"rendered":"http:\/\/www.lonelyword.com\/?p=3"},"modified":"2011-04-14T09:00:50","modified_gmt":"2011-04-14T01:00:50","slug":"wordpress%e5%bb%ba%e7%ab%99","status":"publish","type":"post","link":"http:\/\/www.lonelyword.com\/?p=3","title":{"rendered":"PHP5+Apache2+Mysql\u5efa\u7ad9"},"content":{"rendered":"<p>\u7ec8\u4e8e\u5efa\u597d\u4e86\uff0c\u4e0d\u5bb9\u6613\u554a\u3002<br \/>\n\u9996\u5148\u6211\u662f\u5728\u81ea\u5df1\u673a\u5668\u4e0a\u505a\u5f97\u8bd5\u9a8c\uff0cphp5+apache2+mysql<br \/>\n\u8be6\u7ec6\u914d\u7f6e\u8fc7\u7a0b\uff1a<br \/>\n1.\u9996\u5148\u5b89\u88c5apache_2.2.3-win32-x86-no_ssl.msi<br \/>\n\u76ee\u5f55c:\\web\\<br \/>\n\u8f93\u5165IP,\u663e\u793ait works!\u5b89\u88c5\u6210\u529f<\/p>\n<p>2.\u89e3\u538bphp-5.1.6-Win32.zip<br \/>\n\u76ee\u5f55c:\\web\\php\\<\/p>\n<p>3.\u89e3\u538b<a href=\"http:\/\/lonelyword.googlepages.com\/php5apache2.dll-php5.1.x.rar\" >php5apache2.dll-php5.1.x.rar<\/a>\uff0c\u89e3\u51b3\u4e0d\u517c\u5bb9\u95ee\u9898<br \/>\n\u5b89\u88c5vcredist_x86.exe<br \/>\nphp5apache2.dll\u8986\u76d6c:\\web\\php\\\u539f\u6587\u4ef6<br \/>\nhttpd.exe.manifest\u62f7\u8d1d\u5230c:\\web\\bin\\<\/p>\n<p>4.\u914d\u7f6ePHP\u548cApache\uff0c\u4f7f\u4e4b\u80fd\u89e3\u6790php\u7a0b\u5e8f\u3002<br \/>\n\u628a\u6587\u4ef6php.ini-dist\u62f7\u8d1d\u5230c:\\windows\\\uff0c\u91cd\u547d\u540d\u4e3aphp.ini<br \/>\nC:\\web\\conf\\httpd.conf\u672b\u5c3e\u6dfb\u52a0<br \/>\nLoadModule php5_module c:\/web\/php\/php5apache2.dll<br \/>\nAddType application\/x-httpd-php .php<\/p>\n<p>\u4ee5\u53ca\u6dfb\u52a0<\/p>\n<p>DirectoryIndex index.html index.php<br \/>\n5.\u91cd\u65b0\u542f\u52a8Apache\u670d\u52a1\uff0c\u6d4b\u8bd5\u4ee3\u7801<br \/>\nphpinfo();<br \/>\n?&gt;<\/p>\n<p>6.\u5b89\u88c5mysql-5.0.26-win32<\/p>\n<p>7.\u914d\u7f6e<a href=\"http:\/\/lonelyword.googlepages.com\/php.ini\" >php.ini<\/a>\u5e76\u6d4b\u8bd5mysql<\/p>\n<p>extension_dir = &#8220;c:\/web\/php\/ext\/&#8221; \uff08\u6307\u5b9a\u52a8\u6001\u8fde\u63a5\u5e93\u7684\u76ee\u5f55\uff0cphp5\u548cphp4\u4e0d\u540c\u7684\u5730\u65b9\u5c31\u662f\u5b83\u7684\u52a8\u6001\u8fde\u63a5\u5e93\u76ee\u5f55\u53d8\u4e86\uff0c\u8fd9\u5728\u5b83\u7684\u6587\u6863\u7ed3\u6784\u91cc\u6709\u8be6\u7ec6\u7684\u8bf4\u660e\uff09<br \/>\n\u7136\u540e\u628a\u4e0b\u9762\u51e0\u53e5\u524d\u9762\u7684\u5206\u53f7\u53bb\u6389<br \/>\n;extension=php_dba.dll<br \/>\n;extension=php_dbase.dll<br \/>\n;extension=php_filepro.dll<br \/>\n;extension=php_gd2.dll<br \/>\n;extension=php_imap.dll<br \/>\n;extension=php_mysql.dll<\/p>\n<p>\u63a5\u4e0b\u6765\u4fee\u6539\u4e86\u4e00\u4e9b\u6587\u4ef6\u4e0a\u4f20\u4ee5\u53ca\u5185\u5b58\u4f7f\u7528\u6700\u5927\u9650\u5236\uff1a<br \/>\nmemory_limit = 20M<br \/>\npost_max_size = 20M<br \/>\nupload_max_filesize = 20M<br \/>\n\u522b\u7684\u5c31\u6ca1\u6539\u4ec0\u4e48\u4e86\uff0c\u8fd9\u91cc\u4fee\u6539\u8fc7php.ini\u4ee5\u540e\u4e5f\u8981\u91cd\u65b0\u542f\u52a8apache<\/p>\n<p>\u63a5\u4e0b\u6765\u4e00\u70b9\u5f88\u91cd\u8981\u7684\u5c31\u662f\u628aphp\u76ee\u5f55\u4e0b\u7684 libmysql.dll \u548c libmysqli.dll \u590d\u5236\u5230windows\/system32\u4e0b\uff0c\u5982\u679c\u4e0d\u8fd9\u6837\u505a\uff0cmysql\u52a8\u6001\u8fde\u63a5\u5e93\u5c31\u65e0\u6cd5\u6b63\u5e38\u52a0\u8f7d<\/p>\n<p>\u91cd\u542fapache\u670d\u52a1<br \/>\n\u5728Web\u6839\u76ee\u5f55\u4e0b\uff08\u5982 D:\\website\uff09\u5efa\u7acbtestdb.php\u6587\u4ef6\u5185\u5bb9\u5982\u4e0b\uff1a<br \/>\n$link=mysql_connect(&#8216;localhost&#8217;,&#8217;root&#8217;,&#8217;123456&#8242;);<br \/>\nif(!$link) echo &#8220;fail&#8221;;<br \/>\nelse echo &#8220;success&#8221;;<br \/>\nmysql_close();<br \/>\n?&gt;<br \/>\n\u7528\u6d4f\u89c8\u5668\u6253\u5f00http:\/\/localhost\/testdb.php \u5982\u679c\u8f93\u51fasuccess\u5c31OK\u4e86<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u7ec8\u4e8e\u5efa\u597d\u4e86\uff0c\u4e0d\u5bb9\u6613\u554a\u3002 \u9996\u5148\u6211\u662f\u5728\u81ea\u5df1\u673a\u5668\u4e0a\u505a\u5f97\u8bd5\u9a8c\uff0cphp5+apache2+mysql \u8be6\u7ec6\u914d\u7f6e\u8fc7\u7a0b\uff1a 1.\u9996\u5148\u5b89\u88c5apache_2.2.3-win32-x&#8230;<\/p>\n<p class=\"read-more\"><a href=\"http:\/\/www.lonelyword.com\/?p=3\" > Read More<span class=\"screen-reader-text\">  Read More<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"_uf_show_specific_survey":0,"_uf_disable_surveys":false,"ngg_post_thumbnail":0,"footnotes":""},"categories":[4],"tags":[186,278,174],"aioseo_notices":[],"_links":{"self":[{"href":"http:\/\/www.lonelyword.com\/index.php?rest_route=\/wp\/v2\/posts\/3"}],"collection":[{"href":"http:\/\/www.lonelyword.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.lonelyword.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.lonelyword.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.lonelyword.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=3"}],"version-history":[{"count":0,"href":"http:\/\/www.lonelyword.com\/index.php?rest_route=\/wp\/v2\/posts\/3\/revisions"}],"wp:attachment":[{"href":"http:\/\/www.lonelyword.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=3"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.lonelyword.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=3"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.lonelyword.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=3"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}