通过路径: 仪表盘 —》 媒体 —》 添加新文件
最大上传文件大小: 2MB
修改如下:
vi /etc/php/7.4/apache2/php.ini
upload_max_filesize = 32M
post_max_size = 64M
memory_limit = 128M
重启服务
service php7.4-fpm restart
systemctl restart apache2
量化自我和极简主义的窝藏点
通过路径: 仪表盘 —》 媒体 —》 添加新文件
最大上传文件大小: 2MB
修改如下:
vi /etc/php/7.4/apache2/php.ini
upload_max_filesize = 32M
post_max_size = 64M
memory_limit = 128M
重启服务
service php7.4-fpm restart
systemctl restart apache2
最近想增加友情链接功能,发现最新的WP不知哪个版本把链接功能去掉了,WTF,只能重新找回这个功能。
仪表盘 — 外观 — 编辑
在模版函数(functions.php)的代码最后一行添加
add_filter( ‘pre_option_link_manager_enabled’, ‘__return_true’ );
最后点击“更新文件”,即可看到久违的链接图标
环境:Ubuntu 14.04, wordpress 4.7.1, Apache/2.4.7
由于wordpress本身的链接方法就是?p=1这种方法,不利于搜索引擎索引,因而使用固定链接方法。步骤如下:
到此wordpress的固定链接已经打通。
环境: Ubuntu 14.04, postgresql 9.3, mysql 5.5, wordpress 4.7.1
之前用wordpress 3.4.2和postgresql, pg4wp搭建一个个人博客网站,后来想升级时发现pg4wp从1.3.1之后再也没升级过,这个比较坑了,后续的wordpress都没法再升级上去。没办法,硬着头皮把postgresql替换成mysql。
#postgresql operations,从postgresql上导出数据
\copy wp_postmeta to ‘/home/jerry/postmeta.txt’;
\copy wp_posts ‘/home/jerry/posts.txt’;
\copy wp_links ‘/home/jerry/links.txt’;
\copy wp_terms ‘/home/jerry/terms.txt’;
\copy wp_term_relationships ‘/home/jerry/terms_relationships.txt’;
\copy wp_term_taxonomy ‘/home/jerry/terms_taxonomy.txt’;
#mysql operations,新建数据库wordpress, 并导入之前的数据
CREATE DATABASE wordpress DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci;
delete from wp_postmeta;
delete from wp_posts;
delete from wp_links;
delete from wp_terms;
delete from wp_term_relationships;
delete from wp_term_taxonomy;
load data infile ‘/home/jerry/postmeta.txt’ into table wp_postmeta;
load data infile ‘/home/jerry/posts.txt’ into table wp_posts;
load data infile ‘/home/jerry/links.txt’ into table wp_links;
load data infile ‘/home/jerry/terms.txt’ into table wp_terms;
load data infile ‘/home/jerry/terms_relationships.txt’ into table wp_term_relationships;
load data infile ‘/home/jerry/terms_taxonomy.txt’ into table wp_term_taxonomy;