Generating and setting a custom post title
-
Hello,
I am working with custom posts types and I would like to generate a custom post title using a combination of my custom fields. That way the user doesn’t have to ever enter a title themselves.
Currently I have been using this.
add_filter('title_save_pre','my_function');
with “my_function” grabbing my custom fields and returning a title. That works fine except it only works when I update a post. It doesn’t set the title when I originally create and save the post. How can I fix that? What is the proper method to do this.
Thank You.
Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
- The topic ‘Generating and setting a custom post title’ is closed to new replies.