Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author David Lingren

    (@dglingren)

    Thanks for the good word and for your question. You can use the MLA “Custom Field and Attachment Metadata Processing Options” feature to create custom fields and/or set default values. Here’s how it works:

    1. From the admin Dashboard, scroll down to the Settings section and click the Media Library Assistant entry to open the Settings/Media Library Assistant screen.
    2. Click the Custom Fields tab; have a look through the instructions at the top of the screen.
    3. Scroll down to the “Add a new Custom Field and Mapping Rule” area. (If your “views” field already exists, use the “Add a new Mapping Rule ” area and select your field from the dropdown list).
    4. Enter a name for your new field, e.g., “views”, in the first text box (or select it from the list).
    5. Pull down the Data Source list next to the field name and select “- Template (see below) -“.
    6. Below the Data Source list is a text box. Enter the default value you want to assign here, e.g., enter 99. No other keywords or punctuation marks are required.
    7. Since this is a default value, set the “Existing Text” field to “Keep”. If you ever want to reset all the values, you can use “Replace”.
    8. Use the Native format.
    9. Check the “MLA Column” box, first one to the right of “Format”, if you want to add the field as a sortable column on the Media/Assistant table.
    10. If you want to more easily edit the field manually, check the boxes for the “Quick Edit” and/or “Bulk Edit” areas.
    11. Click the “Add Field (or Rule) and Map All Attachments” button just below the field name text box.
    12. Wait a few moments for the field to be set up and all the data filled in.
    13. Go back to the Media/Assistant submenu. If you checked the “MLA Column” box, your new column should appear on the right-hand side of the directory. Click on the column header to sort on this field.
    14. You can click the “Edit” rollover action for an item to see the field in the item’s “Custom Fields” metabox. If you checked the “Quick Edit” box, you can click the “Quick Edit” rollover action to see the field there as well.

    There is another checkbox at the top of the Custom Fields tab, “Enable custom field mapping when adding new media”. If you leave this box checked (the default), your custom field will automatically be created for any items added to the Media Library after you created the rule.

    If the above process is unclear or if you have any trouble, let me know. You can find more information in the Documentation tab on the Settings page; look for “Custom Field Processing Options” and “Data Sources for custom field mapping” in the list of section heading links at the top of the screen.

    I hope that gets you started on adding the field you need to your Media Library items. Thanks for using the plugin.

    Will

    (@wlanni)

    Wow, so glad you wrote this. I was able to map my custom fields from Advanced Custom Fields plugin, awesome!

    Next thing I’m trying to work out is how to get the template to go from a text input to a checkbox? My ACF field that I’m mapping is a true/false checkbox field. Is there a way to map a custom field as a checkbox using the template?

    Plugin Author David Lingren

    (@dglingren)

    Thanks for the good words and for your question. I want to make sure I understand what you have in mind, since the terms “mapping” and “template” have specific meaning within the context of MLA.

    When you say “mapping”, are you referring to the IPTC/EXIF or Custom Field mapping functions? Or do you mean using the “custom:” prefix to add the field to an [mla_gallery] shortcode?

    When you say “template” are you referring to the custom Markup templates (in the Settings/Media Library Assistant MLA Gallery tab) or to the Content Templates used within an [mla_gallery] shortcode?

    I’m not sure what you mean by “map a custom field as a checkbox”. My best guess is that you want the field to appear as a checkbox in the Quick Edit and Bulk Edit areas; is that right?

    If you can give me more information I can be more helpful.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Bulk edit a custom field value’ is closed to new replies.