WordPress.org

Ready to get started?Download WordPress

Forums

Custom Field Template
mediaPicker in the file field doesn't work. (6 posts)

  1. Ryonosuke Fujii
    Member
    Posted 2 years ago #

    When I set the fieldset to multiple, mediaPicker in the file field doesn't work.

    This is my settings as follows:
    /*----------

    [field_test]
    type = fieldset_open
    multiple = true
    multipleButton = true

    [image]
    type = file
    relation = true
    mediaPicker = true

    --------*/

    When I select a image file, "mediaPicker" doesn't work. And then, the page will be refreshed by compulsion.

    Could you fix this problem? Thank you.

    http://wordpress.org/extend/plugins/custom-field-template/

  2. darkhorse20
    Member
    Posted 2 years ago #

    I'm having the same issue with the Media Picker.

    In Firefox, I turned on the Error Console and found something interesting. When I click on the OR Select by Media Picker link, I get a jQuery error:

    Error: jQuery(this).parent().parent().parent().parent().attr("id") is undefined
    Source File: http://website.com/wp-admin/post.php?post=13&action=edit&message=1

    Looks like it's not working because of a jQuery bug/error/issue.

    I've replicated this with CFT as the only plugin installed and with the TwentyTen theme.

  3. cibea
    Member
    Posted 2 years ago #

    I have same issue,

    and tried this...
    [ Moderated, don't use URLs shortners if you do not have to. ]

    http://wordpress.org/support/topic/plugin-custom-field-template-media-picker-not-inserting?replies=19

    However, I was not able to fix the issue.

  4. darkhorse20
    Member
    Posted 1 year ago #

    I finally figured this out.

    I noticed the Select by Media Picker option doesn't work if you put the code for the media upload inside a fieldset.

    I had it like this:

    [example_fieldset]
    type = fieldset_open
    legend = Example Fieldset

    [imageUpload]
    type=file
    size=40
    relation=true
    hideKey = true
    label = Upload an image
    mediaLibrary = true
    mediaPicker = true
    mediaRemove = true

    [example_fieldset]
    type = fieldset_close

    Removing [imageUpload] outside of the fieldset will make the Select by Media Picker option work.

  5. Karun
    Member
    Posted 1 year ago #

    But if you remove the [imageUpload] and place it outside of the fieldset the how to duplicate it??

  6. darkhorse20
    Member
    Posted 1 year ago #

    Version 2.1.1 fixes this.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic