
DevFixture Numeric Slugs
v1.0.0devfixture · 2026年11月27日 上架
Use numeric slugs such as 125, 001 or 0 for pages, posts and custom post types, with working permalinks and duplicate protection.
- 正在使用
- 10 以下
- 评分
- 暂无
- 累计下载
- 0
- 最近更新
- 2026年11月27日
贡献者
DevFixture Numeric Slugs removes WordPress’s numeric-only slug restrictions. A page requested as 125 can keep 125 instead of becoming 125-2 just because its name is a number.
Built by DevFixture: https://devfixture.com/
- Pages, child pages and deeply nested page trees.
- Posts, including numeric names that overlap date archive patterns.
- Hierarchical and non-hierarchical custom post types.
- Zero and leading zeros are preserved as text.
- Numeric attachment names retain WordPress’s global uniqueness rules.
- Works with the block editor, classic editor, REST API and standard WordPress save functions.
- Real duplicates still receive a suffix. Siblings must be unique; separate parent trees can reuse the same slug.
- No settings screen, frontend assets, database tables, tracking or external services.
Activate the plugin and edit a slug normally. There is no need to resave permalink settings.
URL conflicts
For published, publicly viewable content, an exact numeric permalink takes precedence over a date archive or a page number at the same URL. Private content is resolved only for visitors allowed to read it. Drafts are not made public.
For example, a child page at /guide/2/ takes precedence over page 2 of /guide/. If that child does not exist, WordPress handles pagination normally. A post at /2025/ takes precedence over the 2025 archive. Choose distinct URLs when both destinations need to remain accessible.
WordPress allows pages and posts to share a slug. If they also share the exact same permalink, the page takes precedence. Custom rewrite plugins and two custom post types sharing an identical URL namespace may need their own routing configuration.
The plugin supports standard WordPress pretty permalinks and plain ID-based links. It does not add public URLs to private post types or enable attachment pages disabled by WordPress. Explicit query-string requests retain WordPress’s normal behavior.
Existing content
Existing slugs are not renamed automatically. To change 125-2 to 125, edit the permalink after activation. If 125 is already used in that namespace, the suffix remains necessary. Configure redirects separately when changing a URL already in use.
Deactivation does not rename content. WordPress’s normal numeric restrictions and URL routing apply again, so numeric URLs may require adjustment.