Support Forum » User Profile

Forum Replies Created

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • in reply to: Gutenberg block editor API 3 iframe version #49402
    WolfgangWolfgang
    Participant

    Hey there,
    I've just stumbled across a similar problem. Developped a theme with GB-Blocks and then added the metabox plugin for some CPT and MB-Template extension for registering fields via my theme. I didn't change anything after installation of the AIO Plugin and it took me some time to realize that the blocks which get registered via the "MB Frontend Submission" Plugin using an older version which automatically deactivates the iframe in the editor.

    So as a Note for anyone coming across this problem: Deactivating the MB Frontend Submission Extension solves that problem!

    in reply to: Possible Bug on rwmb_after_save_post #37533
    WolfgangWolfgang
    Participant

    Ok sorry my fault. I wasn't able to combine my wording "field-group" with the wording "field-group" inside the docs where it says that it applies to specific field groups by using the filter like so:
    do_action( "rwmb_{$field_group_id}_after_save_post", $object_id );

    Sorry for that! Please feel free to delete my post!

    in reply to: Custom Fields > Produkt Categories > Oxygenbuilder #32534
    WolfgangWolfgang
    Participant

    Ok, I think I got this wrong ... there is of course no post_id for the categories, so rwmb_meta() won't help here much.

    However you can query the $term_meta and get your custom field with the following snippet:

    <?php
    $term_ID = get_queried_object()->term_id;
    $term_meta = get_term_meta($term_ID);
    echo $term_meta['YOUR_FIELD_NAME'][0];
    ?>
    

    Hope that will help you as well David!

    in reply to: Custom Fields > Produkt Categories > Oxygenbuilder #32533
    WolfgangWolfgang
    Participant

    Hey there,
    funny that the same problem occurs in 2 Days! 😉

    I've nearly the same problem, but I'm using the rwmb_meta() helper function. I'm not sure if I have to use the $post_id parameter, and if so which ID I should use!

    TIA for your help!

    in reply to: rwmb_set_meta in for Settings page field #31901
    WolfgangWolfgang
    Participant

    Hey there,
    any news on that problem? Do you need any further information? Is it a bug or am I doing something wrong?

    TIA for your answer!

    Cheers
    Wolfgang

    in reply to: rwmb_set_meta in for Settings page field #31716
    WolfgangWolfgang
    Participant

    Hi,
    just found that thread here and I'm facing a similiar problem.

    I tried to use the rwmb_set_meta() function for updating a value in a setting page. Unfortunately that value doesn't get updated. Refering to your docs (Docs) i used the option_name as object_id.

    That's what my options-page looks like:

    function wcmvw_settingsPage_register($settings_pages) {
        global $vendorNames;
        //$vendorNames = get_option( 'wcmvw_settings' )['wcmvw_settings_vendorName'];
        $settings_pages[] = [
            'id'            => 'wcmvw_settings',
            'option_name'   => 'wcmvw_settings',
            'menu_title'    => __( 'Rechnungen', 'wcmvw' ),
            'position'      => 0,
            'parent'        => '',
            'style'         => 'no-boxes',
            'columns'       => 1,
            'tabs'          => [
                'wcmvw_settings_general'   => 'Allgemeine Einstellungen',
            ],
            'tab_style'     => 'left',
            'submit_button' => __( 'Änderungen speichern', 'wcmvw' ),
            'message'       => __( 'Änderungen wurden gespeichert!', 'wcmvw' ),
            'icon_url'      => 'dashicons-admin-generic',
        ];
        // Add Tabs dynamically!
        foreach ($vendorNames as $vendor) {
            $settings_pages[0]['tabs'] += [ str_replace(" ", "_", $vendor) => $vendor];
        }
        return $settings_pages;   
    }

    And that's what that specific kind of code looks like:

    $settings_page = get_option('wcmvw_settings');
          $settings_page[$vendorInOrder[$i] . '_wcmvw_invoiceNumberGeneral_field'] = $vendorNextInvoiceNumber+1;
          update_option('wcmvw_settings', $settings_page);
          //rwmb_set_meta( 'wcmvw_settings', $vendorInOrder[$i] . '_wcmvw_invoiceNumberGeneral_field' , 'test' );

    I've commented it out since the "native" option as suggested from you works fine for now. But i would, of course, prefer to use rwmb_set_meta here.

    Any thoughts what I'm doing wrong?

    Thanks in Advance!
    Cheers!

    in reply to: Custom permalink structure for CPT #27332
    WolfgangWolfgang
    Participant

    Hi,
    I'm not sure if I got you right!

    Regarding to your description I can only change (in my example) the CPT-Slug job to lets say job-offer?

    So if I have example.com/job/my-first-job it would change to example.com/job-offer/my-first-job right?
    What I am looking for is to change the permalink structure from %postname% to %post_id% but only for that specific CPT.
    So my link would look like example.com/job/3456
    I didn't manage to do that. The screenshot is showing what I'm trying to achieve in the CPT-Settings
    screenshot

    in reply to: Invalid request. Please try again #27203
    WolfgangWolfgang
    Participant

    Hi
    thanks for your reply. I think I found the problem even though I don't understand it yet.
    I have a php function which creates my custom link in the dashboard which is

    <?php
    
        function clink() {
        $post = get_post();
        $link = "https://my-link.at/form-submission/?rwmb_frontend_field_post_id=" . $post->ID;
        return $link;
        }
    
    ?>

    I am using the "advanced scripts" plugin for php codes since I am using Oxygen and the functions.php is not available. For my understanding the function shouldn't do anything without calling it, right? But the weird thing is, when I set conditions where this .php file should be executed I can use the mbform to update my post.
    https://share.getcloudapp.com/E0uYrpXD
    I've set it to only work on my "dashboard" page.

    My Dashboard page is a custom made page, so I didn't use the "Frontend Dashboard" which is provided by metabox:
    https://share.getcloudapp.com/P8u5yowz
    The button below gets the custom link value as seen in the first share (from the script). That's also the place where I call the function.

    After clicking on the button i will be redirected to my page ../form-submission/?rwmb_frontend_field_post_id=46 where ID is dynamically added.
    https://share.getcloudapp.com/DOuD9Z7A

    So now, since I've set that condition for the script everything works fine, but maybe you can help me understand why I need to set a condition for that script as it shouldn't be executed anyway? Or am I missing something? (not a coder at all :-D)

    Thanks again for your help

Viewing 8 posts - 1 through 8 (of 8 total)