Skip Navigation

[Resolved] Custom fields to be filled in with the author's name in a custom post form

This support ticket is created 3 years, 2 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Karachi (GMT+05:00)

This topic contains 2 replies, has 2 voices.

Last updated by dominiqueM-3 3 years, 2 months ago.

Assisted by: Waqar.

Author
Posts
#2189031
for-toolset-support.png

Tell us what you are trying to do?
Hello,

I try to reproduce the steps of this course (https://toolset.com/lesson-placement/lesson-placements-1622969-1929573/?utm_source=pocket_mylist) which corresponds to what I need to set up for a future site.

I succeeded in creating the account creation and account modification form.
I also created a 'business profile' post form (a custom post type) that each logged in user can use to create a custom post conaining their business information.

To prevent the user from entering the same information several times (first when registering a WordPress account and then in the custom post form for creating the business profile) I would like to know if it is possible to retrieve in some fields of the custom post form the name and first name of the author that is to say the name and first name of the logged-in user.

Thank you

Is there any documentation that you are following?
https://toolset.com/lesson-placement/lesson-placements-1622969-1929573/?utm_source=pocket_mylist

#2189565

Hi,

Thank you for contacting us and I'd be happy to assist.

Yes, this is possible and you can use the "wpv-current-user" shortcode in the target field's default value, to populate the first and last names from the current user:
https://toolset.com/documentation/programmer-reference/views/views-shortcodes/#wpv-current-user

First name:


[wpv-current-user info="firstname"]

Last name:


[wpv-current-user info="lastname"]

Note: as the values in these fields will be pre-filled, you can also hide them using custom CSS code, so that the user can't make changes to these field values.

I hope this helps and please let me know if you need any further assistance around this.

regards,
Waqar

#2189811

My issue is resolved now. Thank you!