Opened 2 years ago

Last modified 2 years ago

#16929 new defect (bug)

pass the $type_of_url context param on user_trailingslashit() for CPT's

Reported by: dd32 Owned by:
Priority: normal Milestone: Future Release
Component: Template Version: 3.1
Severity: normal Keywords: needs-patch
Cc:

Description

Currently get_post_permalink() does not pass the context flag to user_trailingslashit(), this means that for custom post types, it's not possible to target them through the 'user_trailingslashit' filter.

It might be worth checking to see if taxonomies and any other uses of user_trailingslashit() pass the context as well.

Change History (1)

comment:1   dd322 years ago

redirect_canonical() also passes url's through this filter, In the case of *all* single pages(including that of CPT's), the context is set to 'single'.

Note: See TracTickets for help on using tickets.