Forum Replies Created
-
AuthorPosts
-
FizzPop Media
ParticipantReverting to PHP 7.4 does resolve the issue.
However, the original site was built in PHP 8.3 and I can make the same changes on that site with no problem.Please advise.
November 19, 2024 at 2:29 AM in reply to: Custom Admin Column: Uncaught Error: Class "MBAC\Post" not found #46961FizzPop Media
Participantadd_action('admin_init', 'prefix_add_custom_columns', 20); function prefix_add_custom_columns() { require_once 'custom-admin-columns.php'; $post_types = ['vendor';'home']; if (!empty($post_types)) { foreach ($post_types as $post_type) { // Apply custom admin columns to each post type new Prefix_Custom_Admin_Columns($post_type, []); } } }November 19, 2024 at 2:29 AM in reply to: Custom Admin Column: Uncaught Error: Class "MBAC\Post" not found #46960FizzPop Media
ParticipantI have resolved the previous issue.
Now I am trying to add a custom field for any custom post type registered with metabox.
If I hardcode the values of postTypes
vendorandhomein the array it works fine.
However, I can't figure out how to query an array of all postTypes that exist. Please advise.`
add_action('admin_init', 'prefix_add_custom_columns', 20);function prefix_add_custom_columns() {
require_once 'custom-admin-columns.php';
$post_types = ['vendor';'home'];
if (!empty($post_types)) {
foreach ($post_types as $post_type) {
// Apply custom admin columns to each post type
new Prefix_Custom_Admin_Columns($post_type, []);
}
}
}
`FizzPop Media
ParticipantMe too!
FizzPop Media
ParticipantThe issue actually turned out to be that all the items need to be part of a tab. I was thinking that I could have some items outside of all the tabs so I didn't have a tab at the very top. That is what caused the issue.
October 17, 2024 at 4:04 AM in reply to: Bug: Custom Post Type with WYSIWYG and character limit + Bricks = No HTML #46710FizzPop Media
ParticipantI am running metabox 5.10.2, AIO 1.30.2 and Bricks 1.10.3
October 8, 2024 at 11:17 PM in reply to: after_save_post on settings page - values not updated #46630FizzPop Media
ParticipantI am confused.
Is the documentation incorrect?How do I solve for this?
October 7, 2024 at 7:07 PM in reply to: after_save_post on settings page - values not updated #46618FizzPop Media
Participant@Peter
According to your documentation,rwmb-after-save-postworks for settings. Is that incorrect?
https://docs.metabox.io/actions/rwmb-after-save-post/Although the action name is rwmb_after_save_post, it applies to all object types, including term, user, or setting. We keep the name for historical reasons.
My ultimate goal is to calculate a value based on two numbers entered as values into settings:
Inputs:Goal AmountandAmount Raised
Calculate:Goal PercentageasAmount Raised/ `Goal Amount
This is why I am using the after-save-post function
I also tried before-save-post but it also didn't work.FizzPop Media
ParticipantThat is really strange. I swear I didn't change anything but it is definitely no longer there.
You can delete this.FizzPop Media
ParticipantI am attempting to do something similar to this where I need to set the value of
total_bathswhen an entry is saved.total_bathsneeds to be the total offull_bathsandhalf_bathsCan you provide instructions on how I would update the value of
total_bathsbased on the value of the two other fields?August 24, 2024 at 9:07 PM in reply to: ✅calculation in fields | success/error-messages | jQuery version #46231FizzPop Media
ParticipantThe loom is no longer functional in this reply. Also where do you include the jquery code listed?
May 9, 2024 at 9:32 PM in reply to: ✅Relationship Query in Bricks - Unable to sort related entries #45418FizzPop Media
ParticipantFWIW - I seemed to have solved my own issue. The order of the items in the "connects to" section of the related entry controls the order of the related items.
https://nimb.ws/RlNfebY -
AuthorPosts