Plugin not working

Support MB Frontend Submission Plugin not workingResolved

Viewing 13 posts - 1 through 13 (of 13 total)
  • Author
    Posts
  • #21497
    H C WilliamsH C Williams
    Participant

    I just bought the mb frontend form plugin.
    Using the shortcode provided it does not appear to be working:
    https://www.ukaa.org.uk/dev/submit-job-role/

    Please advise if there are known issues or interdependencies that are required to make this plugin work.

    #21500
    Long NguyenLong Nguyen
    Moderator

    Hi,

    The problem is the shortcode was wrapped in the <pre> <code> tag so it just shows the text https://share.getcloudapp.com/jkuZXXdR. In the Block Editor, please use the block shortcode to add the frontend shortcode. In the Classic Editor, please switch to the tab Text to add the shortcode. See my screenshots:
    https://share.getcloudapp.com/9ZuXom6z
    https://share.getcloudapp.com/L1uJXRm4

    Let me know how it goes.

    #21571
    H C WilliamsH C Williams
    Participant

    That's great - now however, I cannot get the shortcode to get my custom fields.

    I can get a basic form to post the title and content into my custom post type "Jobs" but nothing more.

    How can I get the form to register these fields, the title and post into my custom post type "jobs"?

    $meta_boxes[] = array(
        // Meta box id, UNIQUE per meta box. Optional since 4.1.5
        'id' => 'jobs-meta',
        // Meta box title - Will appear at the drag and drop handle bar. Required.
        'title' => __( 'Job Content', 'rwmb' ),
        // Post types, accept custom post types as well - DEFAULT is array('post'). Optional.
        'pages' => array( 'base_jobs' ),
        // Where the meta box appear: normal (default), advanced, side. Optional.
        'context' => 'normal',
        // Order of meta box: high (default), low. Optional.
        'priority' => 'high',
        // Auto save: true, false (default). Optional.
        'autosave' => true,
        // Register this meta box for posts matched below conditions
        //'include' => array('ID'  => array( 4 ),),
        // List of meta fields
        'fields' => array(
                        array(
                            'name' => esc_html__( 'Job Description', 'your-prefix' ),
                            'desc' => esc_html__( 'Enter the Job Description here', 'your-prefix' ),
                            'id'   => "{$prefix}job_desc",
                            'type' => 'wysiwyg',
                            'cols' => 20,
                            'rows' => 3,
                        ),
                        array(
                            'name'  => esc_html__( 'Company name', 'your-prefix' ),
                            'id'    => "{$prefix}job_company",
                            'desc'  => esc_html__( 'Enter company name here', 'your-prefix' ),
                            'type'  => 'text',
                            'clone' => false,
                        ),
                        array(
                            'name'  => esc_html__( 'Job Salary', 'your-prefix' ),
                            'id'    => "{$prefix}job_salary",
                            'desc'  => esc_html__( 'Enter the occupation or status here', 'your-prefix' ),
                            'type'  => 'text',
                            'clone' => false,
                        ),
                        array(
                                            'name'             => __( 'Image', 'rwmb' ),
                                            'id'               => "{$prefix}job_image",
                                            'type'             => 'image_advanced',
                                            'max_file_uploads' => 1,
                                            'desc'               =>'Upload the company logo',
                                        )
                        
    ));
    
    //custom Post Type Jobs////////////////
    $customlabels = array(
      'name' => 'jobs',
      'singular_name' => 'jobs',
      'add_new' => 'Add New',
      'add_new_item' => 'Add New Jobs',
      'edit_item' => 'Edit Jobs',
      'new_item' => 'New Jobs',
      'all_items' => 'All Jobs',
      'view_item' => 'View Jobs',
      'search_items' => 'Search your Jobs',
      'not_found' =>  'No Jobs found',
      'not_found_in_trash' => 'No Jobs found in Trash',
      'parent_item_colon' => '',
      'menu_name' => 'Jobs'
    );
      register_post_type(
        'base_jobs', array(
          'labels' => $customlabels,
          'public' => true,
          'publicly_queryable' => true,
          'show_ui' => true,
          'show_in_menu' => true,
          'query_var' => true,
          'rewrite' => array( 'slug' => 'build-to-rent-job' ),
          'capability_type' => 'post',
          'has_archive' => true,
          'hierarchical' => false,
          'menu_position' => null,
          'menu_icon'=> 'dashicons-portfolio',
          //'supports' => array( 'title', 'editor', 'author', 'thumbnail', 'excerpt', 'comments' )
          'supports' => array( 'title', 'thumbnail'),
          'taxonomies'=> array('category', )
          )
      );
    

    I have tried many combinations like this:

    [mb_frontend_form id="job-content"]
    [mb_frontend_form id="jobs-meta"]
    [mb_frontend_form id="base_jobs"]
    [mb_frontend_form id="base_jobs" post_fields="rw_job_desc,rw_job_company,rw_job_salary,rw_job_image"]

    Please advise.

    #21573
    Long NguyenLong Nguyen
    Moderator

    Hi,

    • Post type slug: base_jobs
    • Meta box ID: jobs-meta
    • Shortcode: [mb_frontend_form id="jobs-meta" post_fields="title,content" post_type="base_jobs"]
    #21584
    Marie PierreANDREIMarie PierreANDREI
    Participant

    Hi,
    I have this message " Fatal error: Call to undefined function wp_enqueue_editor() in /home/casettad/www/wp-content/plugins/meta-box/inc/fields/wysiwyg.php on line 23"
    Can anybody help me please ?

    #21587
    H C WilliamsH C Williams
    Participant

    Hi,

    That bring up the title and content boxes - which work great.
    But there are none of the custom fields, what am I missing to make them show up?

    https://www.ukaa.org.uk/dev/submit-job-role/

    Many thanks again

    #21600
    H C WilliamsH C Williams
    Participant

    Hi Long - any luck with the custom fields on the frontend form?
    We have followed your instruction, but as yet they are not showing.
    Any advise would be greatly appreciated.

    #21614
    Long NguyenLong Nguyen
    Moderator

    Hi,

    Could you please take some screenshots when creating a new post type base_jobs in the backend?

    #21648
    H C WilliamsH C Williams
    Participant

    Hey Sure,
    These images show the whole process of creating a job on the back-end and also show the front-end view after it's created:

    https://ibb.co/P6rcgn8
    https://ibb.co/KxLNNjv
    https://ibb.co/HdRxtz1
    https://ibb.co/XtVpQX0
    https://ibb.co/zHvbKrv

    #21657
    Long NguyenLong Nguyen
    Moderator

    Hi,

    This problem is so weird, please follow this guide to know how to create the staging site https://www.wpbeginner.com/wp-tutorials/how-to-create-staging-environment-for-a-wordpress-site/.

    Then share the credentials (Admin site and FTP account) via this form https://metabox.io/contact/. I will check it out.

    #21719
    H C WilliamsH C Williams
    Participant

    We are already working on a dev site - I will send login details in a moment.
    Many thanks for your help.

    #21802
    H C WilliamsH C Williams
    Participant

    I will recreate the user and resend the details.
    Many thanks.

    #21816
    Long NguyenLong Nguyen
    Moderator

    Hi,

    The problem comes from the code in the file /wp-content/mu-plugins/sitebase/lib/meta-boxes.php line 2339-2355.

    Please register the meta box via the filter rwmb_meta_boxes to show the field in the frontend submission form.

    add_filter( 'rwmb_meta_boxes', function() {
        $meta_boxes[] = array(
            // ...
        );
        return $meta_boxes;
    } );
Viewing 13 posts - 1 through 13 (of 13 total)
  • You must be logged in to reply to this topic.