Support Forum » User Profile

Forum Replies Created

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • DannyDanny
    Participant

    Thanks Peter. I had a feeling someone would've run into this as well. But the search didn't provide this result. Something worth pinning maybe.

    in reply to: Import format for clonable field #44171
    DannyDanny
    Participant

    It's been 2 years..

    I hope this helps someone with a similar use case to mine - using cloneable fields with text fields.

    I've created a CPT with a cloneable text field to add phone numbers. And settled on using WP All Import Pro to import my CSV, instead of WP Ultimate CSV Importer (will explain why after this).

    I found a snippet in WPAI's documentation to "Convert Comma-separated List into Serialized Array" (https://www.wpallimport.com/documentation/code-snippets/#comma-separated-data-to-serialized-array) and this code works too by replcing the comma with a pipe character.

    So in my CSV with the column with multiple phone numbers, I separated each of it with a pipe character.

    In WPAI, imported the CSV, configured my Custom Field, followed the snippet, replaced the comma with pipe character in the Function Editor, ran the import and lo-behold it worked!

    Now, why didn't I use the other importing plugin?

    • Sorely lacking in documentation
    • Could not figure out how to map my taxonomies with sub-categories from documentation
    • Could not figure out how to write the needed Header Manipulation from documentation

    In conclusion, due to the lack of documentation, I just couldn't use that plugin.

    in reply to: How to display custom user meta field on website? #28905
    DannyDanny
    Participant

    Hey Long, I managed to retrieve the value after resetting my WordPress. Not sure what happened there.

    I've got 1 last question..

    I read here (https://docs.metabox.io/fields/select/) that Select will return the Value of the field. Is there a way to display the Label in Elementor?

    in reply to: How to display custom user meta field on website? #28898
    DannyDanny
    Participant

    Unfortunately, linked post wasn't helpful. I'm familiar with retrieving the common User Info via Elementor Pro. And when I tried to view your screen recording in the quoted post, it tells me; This item has exceeded its view limit!

    Anyway.. here's a screenshot of the meta key I'm asking about; https://imgur.com/a/OhBNkEr

    I've tried entering my field ID as you mentioned in another thread (https://support.metabox.io/topic/meta-field-key-without-shortcode/#post-24727). But it's still not retrieving the Select field's value or label.

    If this helps, here's the generated code from my field group via MB builder:

    <?php
    add_filter( 'rwmb_meta_boxes', 'your_prefix_function_name' );
    
    function your_prefix_function_name( $meta_boxes ) {
        $prefix = '';
    
        $meta_boxes[] = [
            'title'  => __( 'Applicant status', 'your-text-domain' ),
            'id'     => 'applicant-status-mb',
            'type'   => 'user',
            'fields' => [
                [
                    'name'    => __( 'Status', 'your-text-domain' ),
                    'id'      => $prefix . 'applicant_status_mb',
                    'type'    => 'select',
                    'options' => [
                        'pending'    => __( 'Pending documents', 'your-text-domain' ),
                        'review'     => __( 'In review', 'your-text-domain' ),
                        'processing' => __( 'Processing', 'your-text-domain' ),
                        'improve'    => __( 'To improve', 'your-text-domain' ),
                        'complete'   => __( 'Completed', 'your-text-domain' ),
                    ],
                ],
            ],
        ];
    
        return $meta_boxes;
    }
    in reply to: How to display custom user meta field on website? #28890
    DannyDanny
    Participant

    I see.

    Well, I've got Elementor Pro and I've installed the MB integrator plugin.

    Now I'm trying to get the status by using User Info (User Meta).

    For the meta key, I've tried using both Field ID and Field Group ID, but I still can't pull the data in Elementor.

    Is the meta key something else?

    in reply to: How to display custom user meta field on website? #28872
    DannyDanny
    Participant

    Hmm.. seems like Metabox isn't as simple as I would've thought it to be for a non-programmer. (-_-||) And most of the documentation is very code driven.

    Guess I'd either shelf this, or take a much longer time wrapping my head around it.

    in reply to: How to display custom user meta field on website? #28861
    DannyDanny
    Participant

    Hey Long, thank you for responding.

    Hmm.. if object_id is meant to retrieve the user ID, then this shortcode may not be usable. Because each user profile will have its own status reflected.

    Secondly, I tried using this
    [rwmb_meta id="status" object_id="2" object_type="user"]

    But the status value did not output when user_id=2 viewed the page with the shortcode.

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