Opened 6 years ago
Closed 6 years ago
#3680 closed defect (bug) (fixed)
Remove post_type_link filter from the WP Parser plugin
Reported by: | keesiemeijer | Owned by: | obenland |
---|---|---|---|
Milestone: | Priority: | normal | |
Component: | Developer Hub | Keywords: | has-patch |
Cc: |
Description
The wporg-developer theme and the WP parser plugin both register the parsed post types but with different slugs. The parser doesn't register the post types if the theme has registered them already, but it does change the permalink for method permalinks in the post_type_link
filter.
If the parser plugin is activated the reference permalink for a method links to
/method/<classname>/<methodname>
While the correct reference permalink for a method is
/reference/classes/<classname>/<methodname>
The following patch removes the post_type_link
filter from the parser as it's not needed for the reference.
Attachments (2)
Change History (7)
#1
@
6 years ago
@keesiemeijer I'm not too familiar with that code, can you point me to an example of the bug for me to test the patch?
#2
@
6 years ago
They both use the post_type_link
filter to change method permalinks . This is more of an annoyance type fix. After parsing you'll have to de-activate the WP Parser plugin for the method permalinks to be correct (and not 404).
They use the filter here
To test it you can activate the WP Parser plugin (and update permalinks) and see if the method permalinks are wrong (without the patch). I assume the WP Parser registers the post types and changes the method permalink so it works without the wporg-developer theme.
remove filter