Media Categories
Organize your media library with custom categories like “Product Photos,” “Blog Graphics,” or “Team Headshots.” Create subcategories for even more organization. Stop scrolling through thousands of images — find what you need instantly.
Use Cases
- Create categories like “Product Photos,” “Blog Graphics,” “Team Headshots” to organize large media libraries
- Use subcategories to organize further (e.g., “Product Photos → Electronics → Phones”)
- Separate client assets on agency multisite networks
- Sort seasonal content (holiday graphics, summer promotions) for easy reuse
How It Works
- Create categories (and optional subcategories) in the module settings
- Go to Media Library in List View
- Use the sidebar to filter by category
- Drag and drop images to assign categories, or use bulk actions
Settings
This module has a category management interface rather than settings. Access it via Switchboard → Media → Media Categories.
Managing Categories
| Action | How to Do It |
|---|---|
| Add category | Type name and click “Add Category” |
| Add subcategory | Select a parent category, then add |
| Edit category | Hover over category, click “Edit” |
| Delete category | Hover over category, click “Delete” |
Deleting a category doesn’t delete the images — they just become uncategorized.
Subcategories (Hierarchical Categories)
Media Categories supports a full hierarchical structure, allowing you to create parent categories with child subcategories.
Creating Subcategories
- Go to the module settings
- In the “Add New Category” form, select a Parent Category from the dropdown
- Enter the subcategory name
- Click “Add Category”
The subcategory will appear indented under its parent in both the settings list and the media library sidebar.
Example Hierarchy
Product Photos
├── Electronics
│ ├── Phones
│ └── Laptops
├── Clothing
└── Accessories
Blog Graphics
├── Featured Images
├── Social Media
└── InfographicsSubcategories in the Sidebar
In the Media Library sidebar, subcategories appear indented under their parents for easy visual hierarchy. Click any category or subcategory to filter the library.
Where to Find It
After enabling, go to Media → Library and switch to List View (icon in the top left). You’ll see:
- Categories sidebar on the left for filtering and drag-drop
- Category column showing each item’s category
- Category filter dropdown in the toolbar
- Bulk actions to assign categories to multiple items
The categories sidebar only appears in List View, not Grid View. A notice will remind you to switch views.
Using the Categories Sidebar
The sidebar shows all your categories with item counts:
- All Media — Show everything
- Uncategorized — Items without any category
- Your Categories — Custom categories with counts (subcategories indented)
Filtering by Category
Click any category in the sidebar to filter the library to show only those items.
Assigning Categories
Method 1: Drag and Drop
- In List View, drag any media row
- Drop it onto a category in the sidebar
- The page refreshes to show updated counts
Method 2: Bulk Actions
- Select multiple items using checkboxes
- Choose “Assign to: [Category]” from the bulk actions dropdown
- Click Apply
Method 3: Remove from Category
- Select items
- Choose “Remove from Category” in bulk actions
- Items become uncategorized
Category Column in List View
A “Category” column shows each item’s current category. Uncategorized items display in gray text.
Tips for Organizing
By Content Type with Subcategories:
- Product Photos
- Electronics
- Clothing
- Accessories
- Blog Featured Images
- Tutorials
- News
- Team Headshots
- Leadership
- Staff
By Project:
- Client: Acme Corp
- Website Redesign
- Marketing Campaign
- Client: Widget Co
- Internal Marketing
By Status:
- Ready to Use
- Needs Editing
- Archive
Gallery Shortcode
Display images from any media category on the frontend using the [switchboard_gallery] shortcode.
Shortcode Builder
Click the Gallery Shortcode button next to any category in the media library sidebar to open the visual shortcode builder. It includes:
- Live preview that updates as you change settings
- Layout selection (Grid or Masonry)
- Column, size, and max image controls
- Link mode (None, File URL, or Lightbox)
- Lightbox navigation toggle (Prev/Next or Disabled)
- Caption toggle
- One-click copy of the generated shortcode
Shortcode Attributes
| Attribute | Default | Options | Description |
|---|---|---|---|
category | — | slug or ID | Required. The media category to display |
layout | grid | grid, masonry | Grid uses uniform cells; Masonry preserves natural aspect ratios |
columns | 3 | 1–6 | Number of columns |
max | -1 | number | Max images to show (-1 = all) |
size | medium | thumbnail, medium, large, full | Image size to use |
link | none | none, file, lightbox | What happens when clicking an image |
nav | yes | yes, no | Show prev/next navigation in lightbox |
caption | no | yes, no | Show caption overlay on images |
spacing | 12 | number (px) | Gap between images |
height | — | CSS value (e.g. 250px) | Fixed row height (grid only) |
orderby | — | date, title, rand, menu_order | Sort order (empty = custom drag order) |
order | DESC | ASC, DESC | Sort direction |
include_children | no | yes, no | Include images from subcategories |
class | — | CSS class | Extra CSS class for styling |
Examples
[switchboard_gallery category="products"]
[switchboard_gallery category="team" layout="masonry" columns="4" link="lightbox" caption="yes"]
[switchboard_gallery category="portfolio" columns="2" size="large" max="12" link="lightbox" nav="no"]Lightbox
When link="lightbox" is set, clicking any image opens a full-screen overlay with:
- Prev/Next buttons — circular arrows on left/right
- Keyboard navigation — Arrow keys and Escape to close
- Image caption displayed at the bottom
- Click outside to close
- Wraps around (last image → first, first → last)
Navigation can be disabled per-gallery with nav="no".
Masonry Layout
The masonry layout uses CSS columns (no JavaScript) to arrange images in a Pinterest-style staggered grid. Images keep their natural aspect ratio instead of being cropped. Responsive breakpoints automatically reduce columns on smaller screens.
FAQ
Do categories affect my site’s front end?
Categories are for backend organization by default. However, you can display categorized images on the frontend using the[switchboard_gallery] shortcode. The taxonomy itself doesn’t create URLs or affect SEO.Can images be in multiple categories?
Currently, each image can only be in one category at a time. Assigning a new category replaces the previous one.Why don’t I see the sidebar?
The categories sidebar only shows in List View. Click the list icon (horizontal lines) in the top-left of the Media Library to switch from Grid View.What happens if I delete a category?
Images in that category become uncategorized. The images themselves are not deleted — only the category assignment is removed. If you delete a parent category, subcategories become top-level categories.Does this work with the Grid View?
Grid View shows a reminder to switch to List View for full category management. The filter dropdown works in both views, but drag-drop and the sidebar require List View.Are categories included in exports?
Yes. Categories are stored as a WordPress taxonomy, so they’re included in standard WordPress exports and can transfer between sites. The parent-child relationships are preserved.How deep can subcategories go?
You can create multiple levels of subcategories. However, for practical usability, we recommend keeping it to 2-3 levels deep (e.g., Category → Subcategory → Sub-subcategory).Get access to all 166 modules with a single license