
內容簡介
Default Permalink 外掛旨在解決 WordPress 自動生成的多位元組字符網址問題,將難以閱讀的網址替換為更簡潔的格式,提升網站的可用性和SEO效果。
【主要功能】
• 將多位元組字符的自動生成網址替換為 {post_type}-{post_ID} 格式
• 保留用戶自訂的多位元組網址不變
• 支援新分類、標籤等的多位元組名稱生成簡潔網址
外掛標籤
開發者團隊
原文外掛簡介
When a post title contains multi-byte characters (such as Japanese), WordPress generates a URL-encoded slug like %e3%81%82..., which results in a long and unreadable permalink.
This plugin replaces such auto-generated slugs with {post_type}-{post_ID} (e.g. post-123). A multi-byte slug is kept as-is when the user has explicitly specified it.
Optionally, new categories, tags and other terms with a multi-byte name can get a slug such as category-12.
Usage
Go to “Settings” -> “Default Permalink” in the WordPress admin.
Check “Enable” and save changes.
WP-CLI
wp default-permalink status shows the settings and the number of posts with a multi-byte slug.
wp default-permalink convert --dry-run lists the posts to convert and their new slugs; wp default-permalink convert converts them all (no 50-post limit).
--post_type=page (comma-separated) converts only those post types, and --limit=500 stops after that many posts so a large site can be converted in steps; the command prints an --after=
Site Health
Tools -> Site Health recommends enabling the plugin when it is installed but not enabled, and shows how many posts still have multi-byte slugs, with a link to the settings screen.
