Tagged: 

Viewing 9 reply threads
  • Author
    Posts
    • #3029
      cosmocanuck
      Member

      Hi again!

      Sorry, I seem to keep running into unfathomable issues trying to set up a couple of grouped fields.

      I’m getting weird display of additional empty field boxes on the back end, as per my attached screen shot. Every time I “Update” or refresh the page, I get a bunch more.

      Additionally, the images and respective captions are not being kept together, the images are being shown in a group.

      (And the image thumbnail display is weird, but I can live with that… perhaps it’s something else worth investigating though.)

      Here’s my code:

      piklist('field', array(
      	'type' => 'group'
      	,'field' => 'nutrition_facts_boxes'
      	,'label' => __('Nutrition Facts')
      	,'description' => __('Upload the Nutrition Facts image.')
      	,'add_more' => true
      	,'fields' => array(
      							array(
      								'type' => 'file'
      								,'field' => 'nutrition_facts'
      								,'label' => __('Nutrition Facts','piklist')
      								,'options' => array(
      								  'basic' => true
      								)
      							)
      
      							,array(
      								'type' => 'text'
      								,'field' => 'nutrition_facts_caption'
      								,'columns' => 12
      								,'label' => __('Caption - only if more than one box','piklist')
      							)
      					)
      ));

      My field names are not duplicated anywhere else, and I’ve looked and looked but can’t find anything wrong with the code. Thanks for any suggestions you can provide!

      Adam

      Attachments:
      You must be logged in to view attached files.
    • #3034
      cosmocanuck
      Member

      Hi again! Here’s some late-breaking news on this developing story…

      I’ve realized that I don’t need to group a “Caption” field with my file upload field after all; I can just use the built-in caption functionality for WP uploads. But before I dismantle my group and delete my “nutrition_facts_caption” text field, I guess it would be good to know why the error described is happening.

      But also…

      Now the thumbnail display issues, as seen in my attached graphic, become a little more pertinent, I think. I’m assuming I should be able to click that thumbnail and get to the standard page where I set the title, caption, etc. of my uploaded file. But I can’t seem to do that.

      I can track it down by file name over in the Uploads area, but that seems awfully cumbersome if there’s a possible easier way to just click through from the thumbnail while I’m editing.

      Let me know… thanks!

    • #3039
      Steve
      Keymaster

      Just pushed v.0.9.4.24 to WordPress.org. This upgrade should fix your image issues.

      Clicking on the image should bring you back to the upgrade screen.

    • #3045
      cosmocanuck
      Member

      The thumbnail’s now correctly shown, however clicking it doesn’t do anything for me.

      Additionally, I’m getting nested “add more” icons/sections for some reason? (See 2nd screen shot attached).

      If I click the outer one, I get additional blank areas (See 1st screen shot.)

      Here’s the entirety of my code for the uploader:

      piklist('field', array(
      	'type' => 'file'
      	,'field' => 'nutrition_facts'
      	,'add_more' => true
      	,'label' => __('Nutrition Facts','piklist')
      	,'options' => array(
      	  'basic' => true
      	)
      ));		

      Thanks for looking into this.

      Attachments:
      You must be logged in to view attached files.
    • #3053
      Steve
      Keymaster

      There seems to be a bug with this type of field config and the BASIC uploader. If you remove the ‘basic’ it should work:

      ,'options' => array(
        'basic' => true
      )
    • #3065
      cosmocanuck
      Member

      That’s definitely better. I notice that clicking the image now takes me to the Add Media page, but that’s not all that helpful, as I still have to search for the image – it would be great if it took me right to the “Edit Media” page for that particular image, where I can add the caption, etc. But, something for the future I guess!

    • #3067
      Steve
      Keymaster

      This is the way the default WordPress media uploader works. Go to add new Post, add a featured image and then click on it again. Should be the same UX.

    • #3068
      cosmocanuck
      Member

      Aha! OK, thanks.

    • #4192
      Kenny
      Member

      The default WordPress media uploader will highlight the featured image where as the file upload field only brings up a media uploader with nothing selected. Is there any way for it to highlight the image that was clicked like it does with featured images?

    • #4195
      Steve
      Keymaster

      @Kenny– Welcome to the Piklist community!

      I’m not perfectly clear on what you’re asking. Can you post a screenshot?

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