惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

T
Tenable Blog
H
Heimdal Security Blog
K
Kaspersky official blog
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
S
Schneier on Security
G
GRAHAM CLULEY
U
Unit 42
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
C
CERT Recently Published Vulnerability Notes
Google DeepMind News
Google DeepMind News
罗磊的独立博客
Stack Overflow Blog
Stack Overflow Blog
阮一峰的网络日志
阮一峰的网络日志
Simon Willison's Weblog
Simon Willison's Weblog
C
Cisco Blogs
Cyberwarzone
Cyberwarzone
T
The Exploit Database - CXSecurity.com
Project Zero
Project Zero
Security Archives - TechRepublic
Security Archives - TechRepublic
www.infosecurity-magazine.com
www.infosecurity-magazine.com
博客园 - 司徒正美
Exploit-DB.com RSS Feed
Exploit-DB.com RSS Feed
V
Visual Studio Blog
博客园 - Franky
Engineering at Meta
Engineering at Meta
WordPress大学
WordPress大学
Jina AI
Jina AI
P
Proofpoint News Feed
P
Proofpoint News Feed
有赞技术团队
有赞技术团队
L
LINUX DO - 最新话题
宝玉的分享
宝玉的分享
N
News and Events Feed by Topic
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
博客园 - 聂微东
T
The Blog of Author Tim Ferriss
Spread Privacy
Spread Privacy
Application and Cybersecurity Blog
Application and Cybersecurity Blog
IT之家
IT之家
S
Security Affairs
博客园 - 叶小钗
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
小众软件
小众软件
N
News | PayPal Newsroom
Cloudbric
Cloudbric
AWS News Blog
AWS News Blog
W
WeLiveSecurity
The Last Watchdog
The Last Watchdog
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
NISL@THU
NISL@THU

wordpress – 百品博客

暂无文章

WordPress开启伪静态教程 - 百品博客
MX文章作者勇敢打破裂缝,阳光就会洒满其中。 · 2026-06-01 · via wordpress – 百品博客

今天刚好有人在Q群里问这个问题,顺便记录一下

后台需要做的

前往设置——固定链接中,选择一个伪静态样式(朴素型不是伪静态)

https://www.baipin.pw/wp-content/uploads/2021/05/Screenshot_20210505_173626-1024x579.jpg

服务器端需要做的

Apache

若为Apache,将以下代码保存为txt文件,再上传到根目录改名为“.htaccess”(注意点)即可。

RewriteRule /tag/(.) /index.php\?tag=$1 RewriteRule /software-files/(.) /software-files/$1 [L]
 RewriteRule /images/(.*) /images/$1 [L]
 RewriteRule /sitemap.xml /sitemap.xml [L]
 RewriteRule /favicon.ico /favicon.ico [L]
 For file-based wordpress content (i.e. theme), admin, etc.
 RewriteRule /wp-(.*) /wp-$1 [L]
 For normal wordpress content, via index.php
 RewriteRule ^/$ /index.php [L]
 RewriteRule /(.*) /index.php/$1 [L]

Nginx

若为Nginx,在nginx.conf内,找到

server { }

在{}内添加以下代码:

location / {
if (-f $request_filename/index.html){rewrite (.*) $1/index.html break;
}
if (-f $request_filename/index.php){rewrite (.*) $1/index.php;
}
if (!-f $request_filename){rewrite (.*) /index.php;
}}

保存,重启即可