WordPress备忘录

url自动生成链接,主题的functions.php中添加下面的代码即可:

1
add_filter('the_content', 'make_clickable');

GeneratePress: 样式表 (style.css)

1
font-family: sans-serif,'宋体';

清理表空间

1
2
3
4
5
6
7
8
DELETE FROM wp_posts WHERE post_type = 'revision';
DELETE FROM wp_postmeta WHERE meta_key = '_edit_lock';
DELETE FROM wp_postmeta WHERE meta_key = '_edit_last';
DELETE FROM wp_postmeta WHERE meta_key = '_wp_old_slug';
DELETE FROM wp_postmeta WHERE meta_key = '_revision-control';
DELETE FROM wp_postmeta WHERE meta_value = '{{unknown}}';
OPTIMIZE TABLE wp_postmeta;
OPTIMIZE TABLE wp_posts;

常用插件

1
2
3
4
5
6
7
8
9
Blackout: Dark Mode Widget	Adds a toggle widget to your website that activates dark mode on click.
Protection against DDoS		Protection against DDoS.
Quotmarks Replacer		Quotmarks Replacer disables wptexturize function that keeps all quotation marks and suspension points in half-width form.
WordPress 导入工具		从 WordPress 导出文件中导入日志、页面、评论、自定义字段、分类、标签或更多内容。
WP-Syntax			Syntax highlighting using GeSHi supporting a wide range of popular languages.
代码美化器			本插件使用Google代码美化器将文章中的代码片段以语法高亮显示。
经典编辑器			启用WordPress经典编辑器和旧式的编辑文章页面,包括TinyMCE、Meta Boxes等。支持扩展此页面的旧插件。
2em				add "text-indent:2em" support to editor.
WP Statistics			此插件为您提供有关网站访问者的完整信息。

refer to:
https://www.wpdaxue.com/wordpress-make-clickable.html
https://www.fujieace.com/wordpress/revisions.html
https://www.91wordpress.com/1963.html
https://blog.csdn.net/weixin_30958745/article/details/113611053