Timeline for Programmatically add custom field to post_name in a custom post type
Current License: CC BY-SA 4.0
6 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Nov 4, 2019 at 15:11 | vote | accept | Chris Wathen | ||
Feb 5, 2019 at 14:21 | comment | added | Chris Wathen | It looks like with Gutenberg, the slug is created while you are typing in the title. I'm able to get the prefix added when I publish the post, then update it. So it's firing the function on the second save of the post. Here is a video showing both Gutenberg and the Classic Editor: screencast-o-matic.com/watch/cqnh2o35vY | |
Feb 5, 2019 at 9:00 | comment | added | hamdirizal | I have also tested it in Guttenberg and it does work. | |
Feb 5, 2019 at 5:33 | comment | added | Chris Wathen | This works when editing the post with the Classic Editor. When I edit it with Gutenberg, the post slug does not include the custom field. | |
Feb 5, 2019 at 1:56 | history | edited | hamdirizal | CC BY-SA 4.0 |
Put more concrete sample.
|
Feb 5, 2019 at 0:47 | history | answered | hamdirizal | CC BY-SA 4.0 |