Using custom fields with Media Attachment

Support General Using custom fields with Media Attachment

Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • #40512
    AnLipAnLip
    Participant

    Hi.
    I would really like to be able to fully use MB with Media Attachments. This way I can query, sort, filter, ... (anything that can be done with other CPTs) with Media Attachments. It will mainly be used for images, since I am developing a photo portfolio. See video for visualization.

    But, after having created a Group Field only applying to Media Attachments, I added a simple checkbox and created a custom taxonomy (applied to Media Attachments only) : I am having all sorts of problems in the way the fields are displayed in the backend, as well as issues with the taxonomy.

    #1 Media modal :
    - Fields display 100% of width of modal, making a simple checkbox absolutely huge in width, barely recognizable and usable. Same for the taxonomy field that is set to "radio list" : each list bullet is 100% of modal...
    - Whether you use the Media display in grid or in list, you have access to a different media modal. The one with the grid does not have this 100% width stretching problem for switches and checkboxes.

    #2 Taxonomy :
    - There is a problem when choosing a taxonomy (I pre-created 4 distinct ones to test) : it creates a new taxonomy that is represented using a number (ID?), instead of accepting the one I selected.
    - Furthermore, the selection applied to the media is not registered (saved), when looking into the admin panel media category list, "0" remains after each value.

    What is wrong ? It has been several times I am trying to use MetaBox plugin with Media Attachment type, and it just never works properly...

    #40513
    AnLipAnLip
    Participant

    Loom video to understand what is going on : https://www.loom.com/share/656e2cfdfe3d416dbea10586f9fd1c33

    #40519
    PeterPeter
    Moderator

    Hello,

    Thank you for your feedback.

    Working with the media modal is not easy because it uses JS code to render and save data also. We are also trying to improve our fields to work with this.

    I'm going to escalate those issues to the development team to fix them. Just one note:
    the selection applied to the media is not registered (saved), when looking into the admin panel media category list, "0" remains after each value
    You are using the field type taxonomy_advanced so it will save the post meta, not set the post terms. Then you will not see the number of posts (image) associated with a taxonomy.

    Please read more on the documentation https://docs.metabox.io/fields/taxonomy-advanced/

    #40533
    AnLipAnLip
    Participant

    If the compatibility of MetaBox was developed in regards to using all of its functionalities with the WP Media Attachments, it would be really great !
    The Media Library could then be used as a much more powerful tool to group attachments (in my case mainly interested in images/photos), create sub-groups, query them, classify them using taxonomies, display them as unique elements in the frontend while pulling their own data.
    And for the admin of the website, it would be great to be able to use the Media modal or whatever other screen to easily add metadata.
    I am aware that some of these functions are already working, but they are still far from being perfect.
    I really hope you can spend some time trying to figure out a way to do so, or maybe develop an new extension for this purpose. Thanks for letting us know if you are working on it. Cheers

    #40560
    PeterPeter
    Moderator

    Hello,

    Thanks for your feedback.

    I've added this to the task and sent it to the development team. They will work on it and I will let you know when I have any information.

    #40566
    AnLipAnLip
    Participant

    This is much appreciated. I hope it leads to something nice. Thank you Peter.

    #42392
    AnLipAnLip
    Participant

    Hi Peter,

    Any news for this matter ? It would be such a good addition to MetaBox...

    #42404
    PeterPeter
    Moderator

    Hello,

    The issues with custom fields in the media modal are fixed. Please update Meta Box to the new version 5.7.3 and recheck these issues.

    #42499
    AnLipAnLip
    Participant

    Thanks Peter, have you also fixed the use of taxonomy fields being attributed to Media Attachments ?

    I have tried outputting custom text fields but with no success. Whether I use the Bricks dynamic data way or a code block and the PHP provided in the MB custom fields editor, either way the values don't show in the frontend. Using the Bricks dynamic data way in a Basic text element leaves the value as such : {mb_attachment_text_line_1} in the frontend, and using the codeblock just outputs nothing...

    #42528
    PeterPeter
    Moderator

    Hello,

    Which is the taxonomy field type? And do you create a custom taxonomy for the attachment post type? Please share some screenshots of the issue on your site.

Viewing 10 posts - 1 through 10 (of 10 total)
  • You must be logged in to reply to this topic.