Forum Replies Created

Viewing 15 posts - 1,996 through 2,010 (of 2,964 total)
  • Author
    Posts
  • in reply to: Documentation suggestion for Workflow Tabs #3142
    Steve
    Keymaster

    Documentation has been updated > Thanks for the suggestion!

    in reply to: About Conditional Custom post list and their taxonomy #3141
    Steve
    Keymaster

    @khairulalamruet– Welcome to the Piklist community!

    To do this you would need to assign all the taxonomies for each Post Type to different fields. Then hide/show the appropriate fields.

    If you provide some more specific code, we would be happy to help you further.

    in reply to: Advanced Add More in Setting Page #3140
    Steve
    Keymaster

    @azizultex– This is really a different post. Your first one was ADVANCED Add-more’s… this is clearly a SIMPLE Add-More. In the future please create a new ticket.

    All you need to do here is:

    $exercises = get_post_meta($post->ID, 'exercise');
    
    foreach ($exercises as $exercise => $value)
    {
      echo $value;
    }
    
    in reply to: Post relationship order #3134
    Steve
    Keymaster

    You should be able to use Meta Query to go the other way. Let me know if that works for you.

    in reply to: Post relationship order #3130
    Steve
    Keymaster

    Currently the Post Relationship field cannot be modified.

    However, you can do something similar if you want.

    In Piklist demos > Advanced Tab > Content Section (Grouped) field. We pull in Posts.

    You can use this field as a guide to create your own. The Post ID would be saved as meta which you can query using get_posts.

    Let us know if you need help.

    in reply to: Documentation suggestion for Workflow Tabs #3129
    Steve
    Keymaster

    @labofoz– great suggestions! We will get the docs updated. Feel free to send a patch to [email protected]

    Thanks again!

    in reply to: Group field add-mores #3126
    Steve
    Keymaster

    @mrioa– I don’t believe Piklist ever allowed descriptions in Grouped fields. You can use ‘help’ instead:

    , 'help => 'Additional info'

    in reply to: Group field add-mores #3124
    Steve
    Keymaster

    @mrioa– Where do you want descriptions? I don’t see it in your code.

    in reply to: Retrieving Data from a Group #3123
    Steve
    Keymaster

    @coreyhunt– Glad you love it! Please use the Demos as a guide. You can literally copy and paste the code into your own projects.

    If you have the time we would really appreciate a 5 Star review on WordPress.org… tell them how impressed you are. It really helps keep the project going.

    in reply to: Retrieving Data from a Group #3120
    Steve
    Keymaster

    @coreyhunt– Welcome to the Piklist community!

    For simple group fields, like yours, you don’t have to assign the group field, to an actual field (i.e. dimensions). If you remove ,'field' => 'dimensions', the other two fields will just save as normal meta data and can be retrieved like this:

    $work_length = get_post_meta($post->ID, 'work-length', true);
    
    echo $work_length;
    

    Also, 99.9% of the time you should not define scope, and just let Piklist automatically set it.

    You new code would look like this:

    piklist('field', array(
      'type' => 'group'
      ,'label' => 'Artwork Dimensions'
      ,'list' => false
      ,'description' => 'Enter the dimensions of the artwork.'
      ,'value' => 'Default text'
      ,'help' => 'In inches.'
      ,'fields' => array(
         array(
          'type' => 'text'
          ,'field' => 'work-length'
          ,'label' => 'Length'
          ,'columns' => 3
          ,'attributes' => array(
            'placeholder' => '0'
          )
        )
    
        ,array(
          'type' => 'text'
          ,'field' => 'work-height'
          ,'label' => 'Height'
          ,'columns' => 3
          ,'attributes' => array(
            'placeholder' => '0'
          )
        )
    
      )
    ));
    

    Let us know if this works for you.

    in reply to: Nested groups problems #3116
    Steve
    Keymaster

    @egamipeaks– Looks like a bug when you use Checkboxes in an advanced grouped add_more. Might not be a quick fix, so I suggest you choose another field configuration.

    in reply to: Select Box For Displaying Posts #3113
    Steve
    Keymaster
    This reply has been marked as private.
    in reply to: Feature Request: Simplified Editor #3104
    Steve
    Keymaster

    @jason– This is fixed in the next beta.

    in reply to: add_more in add_more #3103
    Steve
    Keymaster

    Great! Glad it’s working. Closing ticket.

    in reply to: Repeater Link Field #3101
    Steve
    Keymaster

    @dawood– The code you posted here looks just like the “Page Link” field.

    piklist('field', array(
      'type' => 'select'
      ,'field' => 'dawood'
      ,'columns' => 12
      ,'attributes' => array(
        'multiple' => 'multiple'
      )
      ,'choices' =>  piklist(
                      get_posts(
                         array(
                          'post_type' => 'post'
                          ,'orderby' => 'post_date'
                         )
                         ,'objects'
                       )
                       ,array(
                         'ID'
                         ,'post_title'
                       )
      )
    ));
    

    Since you are setting this field to allow for multiple values selected, you need to loop over the array:

    foreach ($dawood as $key => $value)
    {
      echo '' . get_the_title($value) . '';
    }
    

    The biggest difference here between ACF and Piklist, is that Piklist allows you to use standard WordPress functions like get_permalink() and get_the_title(), while ACF makes you use it’s own functions.

Viewing 15 posts - 1,996 through 2,010 (of 2,964 total)