Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed fatal error: Cannot redeclare addImageThumbnail() in WooCommerce 1.1.6.7 #28

Merged
merged 1 commit into from
Dec 14, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion wooswipe.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
Text Domain: wooswipe
*/

/* Copyright 2010 Dean Oakley (email : dean@thriveweb.com.au)
/* Copyright 2018 Dean Oakley (email : dean@thriveweb.com.au)

This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License, version 2, as
Expand Down Expand Up @@ -237,6 +237,7 @@ function wooswipe_woocommerce_show_product_thumbnails(){
<div class="thumbnails">
<ul class="thumbnail-nav">
<?php
if(!function_exists('addImageThumbnail')){
function addImageThumbnail($attachment_id, $zoomed_image_size){
global $post;
$image = wp_get_attachment_image( $attachment_id, 'shop_thumbnail' );
Expand All @@ -249,6 +250,7 @@ function addImageThumbnail($attachment_id, $zoomed_image_size){
</li>',
$hq[0], $hq[1], $hq[2], $med[0], $med[1], $med[2], $image ), $attachment_id, $post->ID );
}
}

/// add main image
if ( has_post_thumbnail() ) {
Expand Down