Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
woo_image() override
<?php
/*
Plugin Name: woo_image Override
Plugin URI: http://woothemes.com
Description: Override for the woo_image() function in the WooFramework. This will force the active theme to use native WordPress functions for image handling.
Author: Jeffikus
Version: 1.0.0
Author URI: http://woothemes.com
*/
/** WooFramework Override for woo_image()
*
* woo_image() is a legacy function that handled all image output in WooThemes products.
* However, WordPress has proper image handling now, and woo_image() fails in certain conditions.
*
* Instead of modifying extremely complex logic, there is an override filter to bypass its logic.
* Native WordPress functions like the_post_thumbnail() will be used instead of woo_image()
*
* NOTE: This only applies to WooFramework 6.2.1 and above.
*
*/
add_filter( 'woo_image_override', '__return_true' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.