1. 云栖社区>
  2. PHP教程>
  3. 正文

wordpress的helloworld

作者:用户 来源:互联网 时间:2017-12-01 20:48:03

ubuntuwordpress

wordpress的helloworld - 摘要: 本文讲的是wordpress的helloworld,建了个站http://gmtyf.com/http://cn.wordpress.org/使用wordpresswget http://cn.wordpress.org/wordpress-3.3.1-zh_CN.zip配置nginx ph

建了个站http://gmtyf.com/
http://cn.wordpress.org/
使用wordpress
wget http://cn.wordpress.org/wordpress-3.3.1-zh_CN.zip
配置nginx php,fastcgi,指向解压目录
nginx配置为
[email protected]:/home/ubuntu/www# cat /usr/local/openresty/nginx/nginx/conf/nginx.confuser www-data;#user  nobody;worker_processes  4;#error_log  logs/error.log;#error_log  logs/error.log  notice;#error_log  logs/error.log  info;#pid        logs/nginx.pid;events {    worker_connections  1024;}http {	autoindex on; 	autoindex_exact_size off; 	autoindex_localtime on; 	default_type application/octet-stream; 	sendfile on; 	tcp_nopush on;	tcp_nodelay on;	keepalive_timeout 10;	gzip on;	gzip_min_length 1k;	gzip_buffers 4 8k;	gzip_http_version 1.1;	gzip_comp_level 3;	gzip_types text/css text/xml text/plain application/x-javascript application/xml application/pdf application/rtf application/x-perl application/x-tcl application/msword application/vnd.ms-excel application/vnd.ms-powerpoint application/vnd.wap.xhtml+xml image/x-ms-bmp;#	gzip_disable "MSIE [1-6] /.";	gzip_vary on;	output_buffers 4 32k;	client_max_body_size 20m;	server {		listen       80;		server_name  localhost;		charset utf-8,gb2312;		access_log /home/ubuntu/log/access.log;		location / {			root   /home/ubuntu/www/wordpress;			index  index.html index.htm index.php;		}		location ~ /.php$ { 			fastcgi_pass 127.0.0.1:9000;			fastcgi_index index.php;			set $path_info "/";			set $real_script_name $fastcgi_script_name;			if ($fastcgi_script_name ~ "^(.+?/.php)(/.+)$") { set $real_script_name $1;				set $path_info $2;			} 		} 		location ~ .*/.(gif|jpg|jpeg|png|bmp|swf)$ { 			root /home/ubuntu/www/wordpress;			access_log off;			expires 30d;		} 		location ~ .*/.(js|css|ico)?$ { 			root /home/ubuntu/www/wordpress;			access_log off;			expires 1h;		} 		error_page 500 502 503 504 /50x.html;		location = /50x.html { 			root /home/ubuntu/www/wordpress;		} 		fastcgi_param SCRIPT_FILENAME /home/ubuntu/www/wordpress/$real_script_name;		fastcgi_param script_name $real_script_name;		fastcgi_param path_info $path_info;		include /usr/local/openresty/nginx/nginx/conf/fastcgi_params; 	}}[email protected]:/home/ubuntu/www# 

ubuntu 下mysql设置外部访问:
 mysql -uroot -p grant all on *.* to [email protected]'%' identified by "mima" WITH GRANT OPTION;flush privileges;vim /etc/mysql/my.cnfbind-address           = 127.0.0.1改成ip地址重启mysql:/etc/init.d/mysql restart

参考http://hi.baidu.com/parad1se/blog/item/fad2dbfb3e70e16d024f56e0.html

然后看wordpress/readme.html
配置就行了

wordpress的数据表自动建好了
wordpress的helloworld

以上是云栖社区小编为您精心准备的的内容,在云栖社区的博客、问答、公众号、人物、课程等栏目也有的相关内容,欢迎继续使用右上角搜索按钮进行搜索ubuntu , 的 wordpress ,以便于您获取更多的相关知识。