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

推荐订阅源

Google DeepMind News
Google DeepMind News
Stack Overflow Blog
Stack Overflow Blog
Hugging Face - Blog
Hugging Face - Blog
博客园_首页
T
The Blog of Author Tim Ferriss
博客园 - 叶小钗
N
Netflix TechBlog - Medium
腾讯CDC
C
Check Point Blog
P
Proofpoint News Feed
Engineering at Meta
Engineering at Meta
GbyAI
GbyAI
S
SegmentFault 最新的问题
F
Fortinet All Blogs
美团技术团队
U
Unit 42
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
博客园 - 司徒正美
F
Full Disclosure
Recorded Future
Recorded Future
D
DataBreaches.Net
博客园 - 【当耐特】
Martin Fowler
Martin Fowler
J
Java Code Geeks
I
InfoQ
Y
Y Combinator Blog
A
About on SuperTechFans
AI
AI
爱范儿
爱范儿
Exploit-DB.com RSS Feed
Exploit-DB.com RSS Feed
Forbes - Security
Forbes - Security
W
WeLiveSecurity
M
MIT News - Artificial intelligence
雷峰网
雷峰网
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
Simon Willison's Weblog
Simon Willison's Weblog
Schneier on Security
Schneier on Security
The GitHub Blog
The GitHub Blog
Security Archives - TechRepublic
Security Archives - TechRepublic
aimingoo的专栏
aimingoo的专栏
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
G
GRAHAM CLULEY
Know Your Adversary
Know Your Adversary
Latest news
Latest news
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
D
Docker
Recent Commits to openclaw:main
Recent Commits to openclaw:main
量子位
V2EX - 技术
V2EX - 技术
Project Zero
Project Zero

思有云 - IOIOX - Typecho

支持 typecho 1.2 的评论邮件通知插件 LoveKKCommentModify - 思有云 Typecho博客全站部署腾讯云CDN教程 - 思有云 - IOIOX Typecho隐藏不显示某一个特定分类教程 - 思有云 - IOIOX Apache设置Typecho伪静态去掉index.php教程 - 思有云 - IOIOX Nginx设置Typecho伪静态去掉index.php教程 - 思有云 - IOIOX 群晖NAS安装配置typecho博客教程 - 思有云 - IOIOX
宝塔面板设置Typecho伪静态去掉index.php教程 - 思有云 - IOIOX
博主: Stille · 2019-03-07 · via 思有云 - IOIOX - Typecho
  • 发布时间:
  • 12763 次浏览
  • 2 条评论
  • 1585字数
  • 分类: 运维部署
  1. 首页
  2. 正文  

前言

Typecho博客初始安装完成后,博客的任何内页面,地址栏都会有index.php(例如https://www.ioiox.com/index.php/archives/about.html)非常影响美观和网站结构,本文将详解在宝塔面板各环境下如何设置伪静态来去掉index.php

本文为 Stille 原创文章.经实践,测试,整理发布.如需转载请联系作者获得授权,并注明转载地址.


Typecho开启伪静态

  1. 登录管理界面
  2. 设置
  3. 永久链接
  4. 启用地址重写功能
  5. 勾选仍然启动此功能
  6. 选择wordpress风格
  7. 保存设置

关于风格选择,你可以在本文结束后自行在修改成你喜欢的链接风格.

1.jpg

博客配置完毕后,需要配置Web服务器才能生效,请继续参考以下教程.

宝塔面板配置伪静态

宝塔面板分为LNMP和LAMP两种环境,以下分别介绍:

LNMP

  1. 登录宝塔面板
  2. 网站
  3. 设置
  4. 伪静态
  5. 选择typecho
  6. 保存配置完成

选择typecho时,还会有typecho2的选择.如果使用域名直接安装博客,例如本站https://www.ioiox.com 为博客首页,那么请选择typecho.如果域名已经有其他主页,希望在二级子目录来安装博客,例如https:/www.ioiox.com/typecho 为博客首页,那么请选择typecho2.

2.jpg

LAMP

  1. 登录宝塔面板
  2. 网站
  3. 设置
  4. 伪静态
  5. 保持默认0.当前
  6. 添加以下代码
  7. 保存配置完成

由于LAMP环境没有预设typecho的伪静态代码,这里需要手动添加.

<IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule ^(.*)$ index.php [L,E=PATH_INFO:$1]
</IfModule>

3.jpg


结语

本文详解了如何在宝塔面板的各环境下设置Typecho伪静态去掉index.php,本站还介绍了在Nginx和Apache的设置伪静态的教程,推荐相关文章以供参考:

Nginx设置Typecho伪静态去掉index.php教程
Apache设置Typecho伪静态去掉index.php教程

晚高峰稳定 4K 的 IPLC 机场 解锁各流媒体 支持 ChatGPT. 晚高峰稳定 4K 的 IPLC 机场 解锁各流媒体 支持 ChatGPT. RedteaGO - 最划算的大陆漫游 eSim 流量卡,原生境外 IP,注册就送 3 刀。
RedteaGO - 最划算的大陆漫游 eSim 流量卡,原生境外 IP,注册就送 3 刀。

赞赏作者

如果喜欢我的文章,觉得对你有帮助,请随意赞赏!

宝塔面板设置Typecho伪静态去掉index.php教程

 •