PeepSo Documentation

Filter: custom cover size

Hook
peepso_filter_cover_sizes_to_delete

 

Plugin PeepSo Foundation
Since 1.11.4
Status Active
Args
array(int)

Description

To use a custom cover size in your theme or plugin, simply pass an integer to PeepSoUser::get_cover($value). Custom sized images are generated on-the-fly and stored in the user’s directory.

If you do use custom cover images by passing an integer to PeepSoUser::get_cover(), you should hook into this filter to make sure your custom sized cover is deleted when the user removes it.

Examples

Let’s say you use a custom sized cover of 666 somewhere in your plugin or theme:

Since PeepSo creates a file on-the-fly if needed, make sure the file is cleaned up when user removes his cover. To do that, you need to add your custom size to the array of integers.

Get 10% off and a free eBook!

Subscribe to our newsletter to get a welcome discount:  10% off your first purchase* and receive a  free eBook:

"The Secrets Of Successful Online Communities"

* The discount code can only be used once, on a new purchase, not a renewal or upgrade. Promotions can't be combined.