当前位置:网站首页>How to set pseudo static for WordPress fixed links
How to set pseudo static for WordPress fixed links
2022-07-25 23:08:00 【fmamcn】

wordpress The default link form of the page is ” simple ” The way ( for example : http:// domain name /?p=123)
This dynamic URL Links are not convenient for search engines , So , We need to set it to several other common Fixed links form , Such as http://www.zztuku.com The choice is 【 Custom structure 】.
The setting method is as follows :
Get into wordpress Home page of background system , Click menu 【 Set up 】- 【 Fixed links 】

choice 【 Common settings 】 Under the 【 Custom structure 】 , You can select a single label or multiple label combinations , Customizable splicing string , This site uses /%post_id%.html, After filling in , Click on 【 Save changes 】 Effective .

After saving the changes , Although the links of articles or pages become fixed links , But when visiting the page , Instead, it becomes a download operation , Cannot access this URL Address , You need to configure nginx Of Pseudostatic (URL Rewrite) The rules .
The following is a nginx Configuration of , It needs to be modified to your own domain name and root route .
- server {
- listen 80;
- server_name www.example.com;
- root /usr/local/www/wordpress;
- index index.php index.html index.htm;
- location / {
- try_files $uri $uri/ /index.php?$args;
- }
- rewrite /wp-admin$ $scheme://$host$uri/ permanent;
- location ~ \.php$ {
- fastcgi_pass 127.0.0.1:9000;
- fastcgi_index index.php;
- fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
- include fastcgi_params;
- }
- }
After modifying the configuration , restart nginx Effective , Resume normal access .
- systemctl restart nginx.service
Website of this article :https://www.zztuku.com/cms-1401.html
Please state that the reprint is from : Stationmaster Gallery - Wordpress How to set pseudo static for fixed links
边栏推荐
- Analysis of direction finding error of multi baseline interferometer system
- CMU AI PhD first year summary
- SSH服务器CBC加密模式漏洞(CVE-2008-5161)
- 关于优先队列
- anaconda安装教程环境变量(如何配置环境变量)
- 2020-09-17
- Design of Butterworth filter and drawing of amplitude frequency characteristic curve
- Explain in detail the addition (+) operation in JS, basic data type addition, reference data type addition, and the underlying operation rules, [] + {}, {} + []
- The small icon of notification setting shows a small square
- uvm_hdl——DPI在UVM中的实现(四)
猜你喜欢
随机推荐
js正则表达式匹配ip地址(ip地址正则表达式验证)
单元测试,写起来到底有多痛?
ASP date function (what if the disk function is incorrect)
Explain in detail the addition (+) operation in JS, basic data type addition, reference data type addition, and the underlying operation rules, [] + {}, {} + []
R language drawing parameters (R language plot drawing)
Solve the problem phpstudy failed to import the database
MySQL data type
单模型常识推理首超人类!HFL登顶OpenBookQA挑战赛
Simulink学习笔记(三)——Simulink自动代码生成(二)「建议收藏」
About using NPM command under the terminal, the installation error problem is solved (my own experience)
MathType安装和解决不能Crtl+V的问题
[tensorflow] 关于 seed
[tensorflow] about seed
Mocha test
[opencv] edge detection [API and source code implementation]
Wamp MySQL empty password
Similarities and differences between equals and "= ="
Madness. Smbms (supermarket order management system)
Expression of directional signal -- complex exponential signal
[文献阅读] - HRL -[HRL with Universal Policies for Multi-Step Robotic Manipulation]








