Plugin info

Total downloads: 5,722
Active installs: 100
Total reviews: 0
Average rating: 0
Support threads opened: 0
Support threads resolved: 0 (0%)
Available in: 1 language(s)
Contributors: 1
Last updated: 10/28/2013 (4447 days ago)
Added to WordPress: 10/1/2012 (13 years old)
Minimum WordPress version: 3.0.1
Tested up to WordPress version: 3.7.41
Minimum PHP version: f

Maintenance & Compatibility

Maintenance score

Possibly abandoned • Last updated 4447 days ago

20/100

Is Grayscale abandoned?

Possibly abandoned (last update 4447 days ago).

Compatibility

Requires WordPress: 3.0.1
Tested up to: 3.7.41
Requires PHP: f

Similar & Alternatives

Explore plugins with similar tags, and compare key metrics like downloads, ratings, updates, support, and WP/PHP compatibility.

Real Accessability
Rating 4.9/5 (7 reviews)Active installs 2,000
FooGallery ZOOM Template
Rating 0.0/5 (0 reviews)Active installs 1,000
Black Ribbon
Rating 5.0/5 (2 reviews)Active installs 500
Mourning
Rating 5.0/5 (2 reviews)Active installs 300
Grayscale Body
Rating 5.0/5 (6 reviews)Active installs 200
WP Mourning
Rating 4.3/5 (3 reviews)Active installs 100

Description

Sometimes, your website design requires to turn pictures in black & white : for example in a gallery display, you can have all thumbnails in grayscale and bring up colors when the mouse is hovering it.
This plugin will make it possible without the need to manualy create the grayscale variant of each picture.

In your theme’s functions.php, instead of using WP add_image_size function, use grayscale_add_image_size('custom_size', xxx, yyy, $crop, $grayscale) (with $crop set to true if you want to crop the image, and $grayscale set to true if you want a grayscale version of the image). Then, you can use the_post_thumbnail or any thumbnail function to get your grayscale image :

the_post_thumbnail('custom_size-gray')

A gamma correction is applied automatically to make the black & white pictures look good. From version 1.2, You can tune this gamma correction with the grayscale_gamma_correction filter. Your filter would have to return a float number that will be use as the outputgamma parameter of the imagegammacorrect function.

Known bugs

  • Grayscale images are not generated when the original image size is smaller than the specified thumbnail size.

Installation

Upload the plugin files in your wp-content/plugins directory and go to the Plugins menu to activate it.

This plugin requires the GD php library bundled with PHP since version 4.0.6. You will be notified if your system does not support it, and you will be able to activate the plugin.

Frequently Asked Questions

Do I still have to use add_image_size if I want a colored version of my images ?

No, a colored thumbnail at the specified size is already created. You can display it with the_post_thumbnail('custom_size') whereas the black and white one will use the_post_thumbnail('custom_size-gray').

Review feed

No reviews available

Screenshots

No screenshots available

Changelog

1.0

  • Initial version

1.1

  • Minor change in documentation

1.2

  • Remove wp_load_image use (deprecated)
  • Use a class that extends WP_Image_Editor_GD
  • Add grayscale_gamma_correction filter to tune gamma correction