Fix to get sociable icons working for custom post types.
-
I am trying to use Sociable on a WP based shopping cart run using the “The Cart Press” plugin, and out of the box the sociable icons would not be added to the product pages, which are really a custom post type created by the cart press plugin.
Adding the following code replacing line 612 of includes/sociable_output.php seems to have fixed the problem.
$types = get_post_types( $args, 'names' , 'and'); $types[] = "post"; if( is_single() && in_array(get_post_type(), $types)){
It would be great if this functionality could be built into the plugin for future users, or possibly made into an option (eg “display on these post types”).
Hopefully this will help someone, in looking for a solution I saw at least one other person with this same problem.
Viewing 6 replies - 1 through 6 (of 6 total)
Viewing 6 replies - 1 through 6 (of 6 total)
- The topic ‘Fix to get sociable icons working for custom post types.’ is closed to new replies.