Viewing 2 reply threads
  • Author
    Posts
    • #7982
      openmic
      Participant

      Hi Everyone
      I am hoping someone can explain were I am going wrong. Really enjoying piklist and everything is working exactly how I wanted it to until I got to the Form part for the front end.

      To give this in Order, this is the taxonomy that works fine on the back end form.

      /** Artist Taxonomy Starts Here */
      add_filter( ‘edd_download_category_args’, ‘edd_cat_args’);

      // add artist taxomomy
      if ( ! function_exists( ‘artist_taxonomies’ ) ) {
      function artist_taxonomies($taxonomies){
      $singular = ‘Artist’;
      $plural = ‘Artists’;
      $taxonomies[] = array(
      ‘post_type’ => ‘download’
      ,’name’ => ‘download_artist’
      ,’show_admin_column’ => true
      ,’configuration’ => array(
      ‘hierarchical’ => false
      ,’labels’ => get_labels($singular, $plural)
      ,’hide_meta_box’ => false
      ,’show_ui’ => true
      ,’query_var’ => true
      ,’rewrite’ => array(
      ‘slug’ => ‘artists’
      )
      ,’capabilities’ => array( ‘manage_terms’ => ‘manage_product_terms’,’edit_terms’ => ‘edit_product_terms’,’assign_terms’ => ‘assign_product_terms’,’delete_terms’ => ‘delete_product_terms’ )
      )
      );
      return $taxonomies;
      }
      }

      And This is the form I can’t get to save. According to the Documentation the “scope” should be the saved location in the database which is Terms and Termmeta.

      <?php
      /*
      Title: ARTIST REG
      Description: Artists Name and Profile
      Taxonomy: download_artist
      Post_type: download
      Logged in: true
      */
      ?>

      <?php

      piklist(‘field’, array(
      ‘type’ => ‘text’
      ,’scope’ => ‘terms’
      ,’field’ => ‘name’
      ,’label’ => ‘Artist Name’
      ,’columns’ => 10
      ,’description’ => ‘Description goes here’
      ,’attributes’ => array(
      ‘class’ => ‘regular-text’
      ,’placeholder’ => ‘Your Artists or Groups/Bands Name’
      )
      ,’required’ => true
      ));

      piklist(‘field’, array(
      ‘type’ => ‘file’
      ,’scope’ => ‘termmeta’
      ,’field’ => ‘upload_media’
      ,’label’ => ‘Add Photo’
      ,’description’ => __(‘Description goes here’)
      ,’options’ => array(
      ‘modal_title’ => ‘Add Photo’
      ,’button’ => ‘Add Photo’
      )
      ,’required’ => false
      ));

      piklist(‘field’, array(
      ‘type’ => ‘editor’
      ,’scope’ => ‘termmeta’
      ,’field’ => ‘content’
      ,’label’ => ‘Profile and Bio’
      ,’description’ => __(‘Description goes here’)
      ,’options’ => array (
      ‘wpautop’ => true,
      ‘media_buttons’ => false,
      ‘shortcode_buttons’ => false,
      ‘teeny’ => false,
      ‘dfw’ => false,
      ‘quicktags’ => true,
      ‘drag_drop_upload’ => true,
      ‘placeholder’ => ‘Your Artists or Groups/Bands Name’,
      ‘tinymce’ => array(
      ‘resize’ => true,
      ‘wp_autoresize_on’ => true

      )
      )
      ,’required’ => false
      ));

      piklist(‘field’, array(
      ‘type’ => ‘submit’,
      ‘field’ => ‘submit’,
      ‘value’ => ‘Add New Artist’
      ));

      ?>
      I am hoping someone can explain what I have missed or am doing wrong as I can’t for the life of me figure it out.

      Thank You

    • #8012
      Jason
      Keymaster

      Hey @openmic!

      Sorry for the delayed response. Please understand this is a passion project and no one gets paid. We do the best we can, but it’s difficult to keep up. We’re always working to get the community more involved so experienced users can help one another and contribute to make Pklist even better, which is why we recently opened it up on Github.

      For your issue, your scopes are incorrect. Change the following:

      terms -> taxonomy

      termmeta -> term_meta

      Hope this helps! 🙂

    • #8015
      mcmaster
      Member

      @openmic: Just a suggestion, if you put your code into the “code” tags supported by the forum editor, it will make it a lot easier for the volunteer helpers to see what’s going on. 🙂

Viewing 2 reply threads
  • You must be logged in to reply to this topic.