Opened 5 years ago
Closed 3 years ago
#8167 closed enhancement (duplicate)
Unable to create 2 categories with the same title under different parents
| Reported by: |
|
Owned by: |
|
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | Taxonomy | Version: | 2.7 |
| Severity: | normal | Keywords: | close |
| Cc: |
Description
If you attempt to create 2 categories: \Category1\TestCategory and \Category2\TestCategory, TestCategory will fail to be created under the 2nd category, failing on "The category you are trying to create already exists."
It appears that category_exists() which in turn calls is_term() doesnt support hierarchies, Instead mearly checking to see if a Term with that Name exists within the taxonomy.
Partially related to: #5034
Change History (10)
comment:1
janeforshort — 4 years ago
- Milestone changed from 2.8 to 2.9
- Type changed from defect to enhancement
- Keywords needs-patch added
- Milestone changed from 2.9 to Future Release
This has been "fixed" during #11838 (I assume)
The slugs created seem a bit strange however.. but the Names work.
Eg:
Category: Test Parent: None slug: test URL: /category/test/ Category: Test Parent: Parent Cat slug: test-parent-cat URL: /category/parent-cat/test-parent-cat/
- Keywords needs-patch removed
- Milestone changed from Future Release to 3.0
comment:8
prettyboymp — 3 years ago
Can't we close this and have any fixes to the slugs (if any) be put under #5034?
comment:9
prettyboymp — 3 years ago
- Keywords close added
comment:10
dd32 — 3 years ago
- Milestone 3.0 deleted
- Resolution set to duplicate
- Status changed from assigned to closed
Note: See
TracTickets for help on using
tickets.

The requirement for a unique name for categories regardless of hierarchy is documented in the codex, so this should be categorized (heh) as a feature request/enhancement rather than a defect.