- This topic has 2 replies, 2 voices, and was last updated 8 months, 2 weeks ago by .
-
Topic
-
Hi,
Thanks for the great plugin and for your great support team.
I`v created a user profile form and it works fine in the front-end. but the form fields not showing in the admin dashboard.
I`m using Meta Box version 5.3.0 & MB User Profile Version 1.7.0
here is my code:
function register_user_profile_fields($meta_boxes) { $prefix = 'user_profile_'; // fields $meta_boxes[] = [ 'id' => $prefix . 'edit_form_basic', 'title' => 'Your basic information', 'type' => 'user', 'fields' => [ // Email Address Field. [ 'id' => 'user_email', 'type' => 'email', 'name' => 'Email address', 'readonly' => ( wp_get_current_user()->user_email ) ? true : false, 'required' => true ], // Job Title Field. [ 'name' => 'Title (position)', 'id' => 'user_job_title', 'type' => 'text', 'required' => true ], // First Name Field. [ 'id' => 'first_name', 'name' => 'First name', 'type' => 'text', 'required' => true ], // Last Name Field. [ 'id' => 'last_name', 'name' => 'Last name', 'type' => 'text', ], // Phone Number Field. [ 'name' => 'Phone Number', 'id' => 'user_mobile', 'type' => 'tel', 'required' => true, ], // Gender Field [ 'name' => 'Gender', 'id' => 'user_gender', 'type' => 'radio', 'options' => [ 'Male' => 'male', 'Female' => 'Female', ], ], return $meta_boxes; } add_action( 'rwmb_meta_boxes', 'register_user_profile_fields',2, 1);
and here is my shortcode
echo do_shortcode( '[mb_user_profile_info id="user_profile_edit_form_basic" form_id = "edit_user_profile" submit_button="Save" confirmation="Your information has been successfully submitted. Thank you." ]' );
Thanks in advanced,
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- You must be logged in to reply to this topic.