This plugin is ideal for blog owners who like to do something more with their images, or for webshop owners who like to filter products by color. When inserting images you have the option to show the palette for that image. You can also use the following shortcode to show a specific image with palette:
[colorpalette attachment="56" dominant="false" colors="10" size="large" random="true"]
Features
- Generate color palettes per image
- Bulk-generate color palettes for all images
- Allows configuration of number of unique colors per image
- Allows configuration of auto appending palettes on attachment pages
- See stats of generated palettes
- Filter attachments by color
- Add color search widget to your sidebar
- Use a shortcode to show an image with a palette in your content.
Developers
If you don't like the way the plugin outputs the palettes, or you want to create custom color queries yourself, use the wordpress taxonomy functions. There are 2 new taxonomies added when the plugin is activated:
cpg_dominant_color
and
cpg_palette
. The first one holds one color per image, the dominant color (this color is used to link the image to one of the main colors used in the color search functions). The second one holds the palette, and the number of colors is based on what the site owner has entered (default = 10).
Special thanks
TODO
- Better uninstall functions (attachment meta needs to be removed)
- Generate palette on upload