Forum Replies Created
-
AuthorPosts
-
[email protected]
Participant"Do you think it would be possible to complete this order custom fields during the WooCommerce checkout process?"
I know this is an older post, but it depends on what you are wanting to send to the cart and checkout, but yes you can with a bit of custom code.
Cheers
November 3, 2025 at 8:02 PM in reply to: ✅Frontend Submission --> Custom Title and Slug from Fields #49271[email protected]
ParticipantI know this is an older post, but thought I would add to it, as it is a great feature that MB has.
In my case I have a form that is capturing submissions, so like a contact form. I created a custom post type of "Submissions" and then added the custom fields I wanted on that form.
Now, I did not want the Post Title to be on the frontend, but if you remove it you get an error and if you hide it, the submission captures and empty field. So I took the code above that John submitted an modified it a bit. Now when the form is submitted the Post Title entry is the user's First and Last name.
Hope this helps. =]
add_action( 'rwmb_frontend_after_save_post', 'update_submission_post_title'); function update_submission_post_title( $object ) { $post_type = $object->post_type; if ( 'submission' == $post_type ) { $post_id = $object->post_id; // Get both field values $first_name = rwmb_meta( 'first_name', '', $post_id ); $last_name = rwmb_meta( 'last_name', '', $post_id ); // Combine the names $full_name = trim( $first_name . ' ' . $last_name ); // Only update if we have a name if ( ! empty( $full_name ) ) { // Prepare update post $my_post_title = array( 'ID' => $post_id, 'post_title' => $full_name, 'post_name' => sanitize_title( $full_name ), ); wp_update_post( $my_post_title ); } } }[email protected]
ParticipantHello Peter,
Thanks for the quick response and pushing it along to the team. =]
Cheers
November 27, 2024 at 10:49 PM in reply to: There seems to be a lot of issues lately .. why is that? #47045[email protected]
ParticipantThanks Peter, I have sent in the info via the contact form.
Cheers
November 27, 2024 at 7:31 AM in reply to: There seems to be a lot of issues lately .. why is that? #47033[email protected]
ParticipantIf debug is on and I activate Metabox AIO, I get this message: Notice: Function WP_Block_Type_Registry::register was called incorrectly. Block type names must contain a namespace prefix.
Deactivate AIO and it comes back.
[email protected]
ParticipantHey Peter,
Sorry to bug, but it seems there is still some glitchy weirdness going on. Here is a screen recording showing you when is happening.
Video: https://streamable.com/uo7pqp
Cheers
[email protected]
ParticipantHey Peter,
Yes, all is working now. I did however have to readd the name back in, as it was blank from before. But once readded and saved, all works great.
Thanks again!
[email protected]
ParticipantPerfect, thanks again Peter and to the team, great work as always.
[email protected]
ParticipantExcellent, thanks Peter and team for the good work. =]
[email protected]
ParticipantThanks for the link Peter.
Cheers
[email protected]
ParticipantI get the same thing ... I can see the list of custom fields, but when I go into one of them to edit, the fields show, then disappear with the "Something went wrong. Please try again!" error message.
[email protected]
ParticipantHey folks, ignore this posting, as I was able to sort it out. All works fine.
Cheers
[email protected]
ParticipantThanks folks for the quick reply and fix for this. All is working great now with the update: AIO v1.27.1
Cheers
[email protected]
ParticipantYes, I did figure that you the other day when testing, but it would be nice to not have an error if there is no field. But thank you for sending it along to support.
Cheers
[email protected]
ParticipantJust an update ... I have been testing and I found this error happens when you have no fields. Once you add at least one field, there is no error.
Is this the way it should be, or?
Cheers
-
AuthorPosts