Tell us what you are trying to do?
I have a custom post type with a front end form for creating instances of that post type. When I submit the form, the post title is an autogenerated unique id. Instead, I'd like to use one of the custom fields ('name', for example) as the post title.
Is there any documentation that you are following?
https://toolset.com/course-chapter/forms-for-front-end-submission-and-editing-of-directory-items/
My thought was that I could:
- add a Post Title field to the form
- use CSS to make the Post Title field invisible
- use the custom field slug like [name] or $(name) in the Post Title 'Field Default Value'. But that doesn't seem to work.
Can you please refer me to a thread on how to do this? Thanks!
Hi Jordan,
Thank you for getting in touch.
To set the post title with a custom field value I recommend having a look at the link below and let me know if it helps.
https://toolset.com/forums/topic/post-link-from-custom-fields/#post-578003
It uses our toolset forms hook to set the value of the custom field as the post title.
Please let me know if this helps.
Thanks,
Shane
Ah that works great, and it's easy to see how to extend it to other fields. Thanks so much!