default is '%s' )
"), MEDIA_TAGS_URL_DEFAULT ); ?> Note Be careful not to use a prefix that may conflict with other WordPress standard prefixes like 'category', 'tag', a Page slug, etc.", MEDIA_TAGS_I18N_DOMAIN); } function mediatags_settings_panel() { $update_message = ""; if ( (isset($_REQUEST['mediatags_settings_panel'])) && (wp_verify_nonce($_REQUEST['mediatags_settings_panel'], 'mediatags_settings_panel')) ) { $update_message = ""; //echo "_REQUEST
"; print_r($_REQUEST); echo "
"; if (isset($_REQUEST['mediatag_admin_bulk_library'])) { if (strtolower($_REQUEST['mediatag_admin_bulk_library']) == strtolower("yes")) $mediatag_admin_bulk_library = "yes"; else $mediatag_admin_bulk_library = "no"; update_option( 'mediatag_admin_bulk_library', $mediatag_admin_bulk_library ); $update_message = "Media-Tags Settings have been updated."; } if (isset($_REQUEST['mediatag_admin_bulk_inline'])) { if (strtolower($_REQUEST['mediatag_admin_bulk_inline']) == strtolower("yes")) $mediatag_admin_bulk_inline = "yes"; else $mediatag_admin_bulk_inline = "no"; update_option( 'mediatag_admin_bulk_inline', $mediatag_admin_bulk_inline ); $update_message = "Media-Tags Settings have been updated."; } if (isset($_REQUEST['mediatag_template_archive'])) { if (strtolower($_REQUEST['mediatag_template_archive']) == strtolower("yes")) $mediatag_template_archive = "yes"; else $mediatag_template_archive = "no"; update_option( 'mediatag_template_archive', $mediatag_template_archive ); $update_message = "Media-Tags Settings have been updated."; } if (isset($_REQUEST['mediatag_rss_feed'])) { if (strtolower($_REQUEST['mediatag_rss_feed']) == strtolower("yes")) $mediatag_rss_feed = "yes"; else $mediatag_rss_feed = "no"; update_option( 'mediatag_rss_feed', $mediatag_rss_feed ); $update_message = _x("Media-Tags Settings have been updated.", 'update message', MEDIA_TAGS_I18N_DOMAIN); } } $title = _x('Media-Tags Settings', 'settings panel title', MEDIA_TAGS_I18N_DOMAIN); ?>

 
 

 

blogid; $update_message = ""; $current_user_id = get_current_user_id(); $current_user = new WP_User( $current_user_id ); if ( (isset($_REQUEST['mediatags_roles_panel'])) && (wp_verify_nonce($_REQUEST['mediatags_roles_panel'], 'mediatags_roles_panel')) ) { if (isset($_REQUEST['media-tags-user-roles'])) { //echo "_REQUEST
"; print_r($_REQUEST); echo "
"; $mediatags_user_roles = $_REQUEST['media-tags-user-roles']; // if ($current_user->has_cap('edit_users')) { if (floatval($wp_version) >= "3.1") $users = get_users(); else { $users = array(); $user_ids = get_editable_user_ids($current_user_id); if ($user_ids) { foreach($user_ids as $user_id) { $users[$user_id] = new WP_User( $user_id ); } } } if ($users) { foreach($users as $user_id => $user) { if ($user) { //echo "user
"; print_r($user); echo "
"; foreach($mediatags_caps as $mediatags_cap => $mediatags_label) { if ((isset($mediatags_user_roles[$user_id][$mediatags_cap])) && ($mediatags_user_roles[$user_id][$mediatags_cap] == "on")) $user->add_cap($mediatags_cap); else $user->add_cap($mediatags_cap, false); } } } } } $update_message = _x("Media-Tags Roles have been updated.", 'update message', MEDIA_TAGS_I18N_DOMAIN); } } $title = _x('Media-Tags Roles Management', 'settings panel title', MEDIA_TAGS_I18N_DOMAIN); ?>

$role) { $user_roles_array[$role_label] = array(); $user_roles_array[$role_label]['name'] = $role['name']; $user_roles_array[$role_label]['users'] = array(); } if (floatval($wp_version) >= "3.1") $users = get_users(); else { $users = array(); $user_ids = get_editable_user_ids($current_user_id); if ($user_ids) { foreach($user_ids as $user_id) { $users[$user_id] = new WP_User( $user_id ); } } } if ($users) { foreach($users as $user_id => $user) { //echo "user
"; print_r($user); echo "
"; if ( is_multisite() ) { $cap_str = "wp_". $current_blog_id ."_capabilities"; if (isset($user->$cap_str)) $user_capabilities = $user->$cap_str; } else { $user_capabilities = $user->wp_capabilities; } if (isset($user_capabilities)) { foreach($user_capabilities as $cap_idx => $cap_val) { if (isset($user_roles_array[$cap_idx])) $user_roles_array[$cap_idx]['users'][$user->data->display_name] = $user; } } } //echo "user_roles_array
"; print_r($user_roles_array); echo "
"; ?>

  • This option excludes access to the Media-Tags Roles Management panel.", 'role legend text for manage settings', MEDIA_TAGS_I18N_DOMAIN); ?>
  • This option excludes access to the other Media-Tags Settings panels.", 'role legend text for manage roles', MEDIA_TAGS_I18N_DOMAIN); ?>
  • If this option is set you must also set either 'Edit Terms' or 'Delete Terms' roles.", 'role legend text for manage terms', MEDIA_TAGS_I18N_DOMAIN); ?>
  • If you check this option you must also set the 'Manage Terms' Roles option.", 'role legend text for edit terms', MEDIA_TAGS_I18N_DOMAIN); ?>
  • If you check this option you must also set the 'Manage Terms' Roles option.", 'role legend text for delete terms', MEDIA_TAGS_I18N_DOMAIN); ?>
$user_role_data) { //echo "user_role_idx=[".$user_role_idx."]
"; $role = get_role($user_role_idx); //echo "role
"; print_r($role); echo "
"; mediatag_settings_boxheader('mediatag-options-roles-', __('Role', MEDIA_TAGS_I18N_DOMAIN). ': '. $user_role_data['name']); if ((isset($user_role_data['users'])) && (count($user_role_data['users']))) { ?>
capabilities[MEDIATAGS_SETTINGS_CAP])) && ($role->capabilities[MEDIATAGS_SETTINGS_CAP] == 1)) { $role_default = "role-default"; } ?> capabilities[MEDIATAGS_MANAGE_ROLE_CAP])) && ($role->capabilities[MEDIATAGS_MANAGE_ROLE_CAP] == 1)) { $role_default = "role-default"; } ?> capabilities[MEDIATAGS_MANAGE_TERMS_CAP])) && ($role->capabilities[MEDIATAGS_MANAGE_TERMS_CAP] == 1)) { $role_default = "role-default"; } ?> capabilities[MEDIATAGS_EDIT_TERMS_CAP])) && ($role->capabilities[MEDIATAGS_EDIT_TERMS_CAP] == 1)) { $role_default = "role-default"; } ?> capabilities[MEDIATAGS_DELETE_TERMS_CAP])) && ($role->capabilities[MEDIATAGS_DELETE_TERMS_CAP] == 1)) { $role_default = "role-default"; } ?> capabilities[MEDIATAGS_ASSIGN_TERMS_CAP])) && ($role->capabilities[MEDIATAGS_ASSIGN_TERMS_CAP] == 1)) { $role_default = "role-default"; } ?> "; print_r($role_user); echo ""; ?> $media_tags_desc) { $media_tag_role = str_replace('_', '-', $media_tags_cap); $field_id = "media-tags-user-roles-". $role_user->ID ."-". $media_tag_role; $field_name = "media-tags-user-roles[". $role_user->ID ."][". $media_tags_cap."]"; $field_class = "no"; $field_label = _x("No", 'select option', MEDIA_TAGS_I18N_DOMAIN); $field_checked = ""; if ((isset($role_user->allcaps[$media_tags_cap])) && ($role_user->allcaps[$media_tags_cap] == 1)) { $field_class = "yes"; $field_label = _x("Yes", 'select option', MEDIA_TAGS_I18N_DOMAIN); $field_checked = ' checked="checked" '; } ?>
data->ID; ?>data->display_name; ?>data->display_name)) != (strtolower($role_user->data->user_email))) { echo " (". $role_user->data->user_email .")"; } ?>data->ID."]
"; //echo "media_tags_cap=[".$media_tags_cap."]
"; if ($role_user->data->ID == $current_user_id) { if (($media_tags_cap != MEDIATAGS_SETTINGS_CAP) && ($media_tags_cap != MEDIATAGS_MANAGE_ROLE_CAP) ) { ?> /> />

"; print_r($_REQUEST); echo ""; if (isset($_REQUEST['mediatag_google_plugin'])) { if (strtolower($_REQUEST['mediatag_google_plugin']) == strtolower("yes")) $mediatag_google_plugin = "yes"; else $mediatag_google_plugin = "no"; update_option( 'mediatag_google_plugin', $mediatag_google_plugin ); $update_message = _x("Media-Tags Third Party Settings have been updated.", 'update message', MEDIA_TAGS_I18N_DOMAIN); } } $title = _x('Media-Tags Third Party Support', 'settings panel title', MEDIA_TAGS_I18N_DOMAIN); ?>

Know of a plugin you think should be integrated with Media-Tags? Suggest it

)

Library page where you media items are normally listed. But the listing will be filtered to show only those items per that selected Media-Tag. Within the Media > Library page itself there is an additional column added. This column lists the Media-Tags used for the Media Library item.", MEDIA_TAGS_I18N_DOMAIN); ?>

Menus page you will see the Media-Tags listed in the meta boxes on the left side of the page. If you don't see the Media-Tags box try clicking the 'Screen Options' at the top-right of the page. Make sure the Media-Tags is checked.", MEDIA_TAGS_I18N_DOMAIN); ?>

Library section as well as the Post/Page media popup.", MEDIA_TAGS_I18N_DOMAIN); ?>

Library section the Bulk Admin interface is accessed via the WordPress Bulk action dropdown. First you need to select which media items to work with. Then select 'Media-Tags' from the Bulk action dropdown and click the 'Apply' button. You will now see the new Media-Tags Bulk Administration popup. Via this popup you can assign or remove Media-Tag terms from the selected media items. You can also add new Media-Tag terms. Click the 'Submit' button to process. The page will refresh.", MEDIA_TAGS_I18N_DOMAIN); ?>

Media-Tags Settings panel. ", MEDIA_TAGS_I18N_DOMAIN); ?>

Permalinks. Toward the bottom of the page in the Optional section you will see an input field to change the '/media-tags/' URL base to something else like gallery, pictures, etc. Just remember this part of the URL must be unique. For example if you already page a WordPress Page in your system named 'Gallery' most likely the URL for that page will also be http://www.mysite.com/gallery/ This means you cannot change '/media-tags/' also to gallery since this means they would share the same URL which is not allowed.", MEDIA_TAGS_I18N_DOMAIN); ?>

[media-tags media_tags="flags"]', MEDIA_TAGS_I18N_DOMAIN); ?>

[media-tags is required and indicates to WordPress which shortcode functionality to implement. The next part media_tags="flags" is also required. This element tells the system which Media-Tag terms to display. You can use multiple terms here. These terms need to be comma separated.', MEDIA_TAGS_I18N_DOMAIN); ?>

get_posts function. ", MEDIA_TAGS_I18N_DOMAIN); ?>

  • numberposts:
  • tags_compare:
  • media_types:
  • post_type:
  • orderby:
  • order:
  • offset:
  • return_type:
  • search_by:
  • display_item_callback:
  • size:
  • before_list: Default is '<ul>. You can override this default and use an ordered list or an unordered list with a specific class or id attribute. You can include a h2 header for the title before the list.
  • after_list: Default is '</ul>. Obviously this closing element must match the opening element of the 'before_list' parameter.", MEDIA_TAGS_I18N_DOMAIN); ?>

  • get_attachments_by_media_tags:

  • is_mediatag:
  • in_mediatag:
  • has_mediatag:
  • get_mediatags:
  • list_mediatags:
  • get_mediatag_link:
  • the_mediatags:
  • single_mediatag_title:
  • mediatags_cloud""
  • mediatags_description""

  1. taxonomy-media-tags-slug.php example: taxonomy-media-tags-flags.php
  2. taxonomy-media-tags.php example: taxonomy-media-tags.php
  3. taxonomy.php
  4. archive.php
  5. index.php

  1. mediatag-term.php
  2. mediatag-id.php
  3. mediatag.php

Settings) a new RSS output will be provided on any Media-Tags archive page. So when the user views your page http://www.mysite.com/media-tags/flags/ they can also subscribe to the RSS fee of this archive by accessing the URL. http://www.mysite.com/media-tags/flags/feed/. This RSS output can be customized by copying the plugin file 'mediatags_rss.php' into your active theme folder. You can disable the automatic RSS feed option via the Media-Tags > Settings panel. ", MEDIA_TAGS_I18N_DOMAIN); ?>