diff --git a/wp-content/themes/customizr-pro-child/functions.php b/wp-content/themes/customizr-pro-child/functions.php index bf143c7..f1a839b 100644 --- a/wp-content/themes/customizr-pro-child/functions.php +++ b/wp-content/themes/customizr-pro-child/functions.php @@ -8,4 +8,49 @@ // END ENQUEUE PARENT ACTION /*---Move Product Title*/ remove_action( 'woocommerce_before_shop_loop_item_title', 'woocommerce_template_loop_product_thumbnail', 10 ); -add_action( 'woocommerce_after_shop_loop_item_title', 'woocommerce_template_loop_product_thumbnail', 10 ); \ No newline at end of file +add_action( 'woocommerce_after_shop_loop_item_title', 'woocommerce_template_loop_product_thumbnail', 10 ); + +/** + * @return array + * +function child_thumb_size() { + $sizeinfo = array( 'width' => 240, 'height' => 180, 'crop' => false ); + return $sizeinfo; +} +add_filter( 'tc_thumb_size', 'child_thumb_size'); +add_filter( 'tc_thumb_fpc_size', 'child_thumb_size'); + */ + +/** + * +function child_theme_setup() { + add_image_size('tc-thumb', 240, 180, false); +} +add_action( 'after_setup_theme', 'child_theme_setup', 10, 2); +update_option( 'thumbnail_size_w', 240 ); +update_option( 'thumbnail_size_h', 180 ); +update_option( 'thumbnail_crop', 0 ); + */ + +/** + * +add_filter('tc_fp_link_url' , 'my_custom_fp_links', 10 ,2); +//If you are using the featured pages Unlimited Plugin or the Customizr Pro theme, uncomment this line : +add_filter('fpc_link_url' , 'my_custom_fp_links', 10 ,2); + +function my_custom_fp_links( $original_link , $fp_id ) { + + //assigns a custom link by page id + $custom_link = array( + //page id => 'Custom link' + 59 => 'https://newswheel.vta.org/category/headways/', + 29 => 'https://newswheel.vta.org/category/from-the-hub/', + 129 => 'https://newswheel.vta.org/category/announcements/', + 25 => 'https://newswheel.vta.org/category/safety/' + ); + + foreach ($custom_link as $page_id => $link) { + if ( get_permalink($page_id) == $original_link ) + return $link; + } + */ diff --git a/wp-content/themes/customizr-pro-child/style.css b/wp-content/themes/customizr-pro-child/style.css index eccf78e..9eb7a9c 100644 --- a/wp-content/themes/customizr-pro-child/style.css +++ b/wp-content/themes/customizr-pro-child/style.css @@ -67,3 +67,10 @@ h2.woocommerce-loop-product__title { font-size: 12pt !important; color: red; } + +/** + * Fix post thumbnails scaling issue + */ +figure.tc-grid-figure.has-thumb.effect-4 { + height: unset !important; +} \ No newline at end of file diff --git a/wp-content/themes/customizr-pro-child/woocommerce/archive-product.php b/wp-content/themes/customizr-pro-child/woocommerce/archive-product.php index ada4a8f..41b6c89 100644 --- a/wp-content/themes/customizr-pro-child/woocommerce/archive-product.php +++ b/wp-content/themes/customizr-pro-child/woocommerce/archive-product.php @@ -10,121 +10,98 @@ * happen. When this occurs the version of the template file will be bumped and * the readme will list any important changes. * - * @see https://docs.woocommerce.com/document/template-structure/ - * @author WooThemes - * @package WooCommerce/Templates - * @version 2.0.0 + * @see https://docs.woocommerce.com/document/template-structure/ + * @package WooCommerce/Templates + * @version 3.4.0 */ -if ( ! defined( 'ABSPATH' ) ) { - exit; // Exit if accessed directly -} +defined( 'ABSPATH' ) || exit; + +get_header( 'shop' ); -get_header( 'shop' ); ?> +/** + * Hook: woocommerce_before_main_content. + * + * @hooked woocommerce_output_content_wrapper - 10 (outputs opening divs for the content) + * @hooked woocommerce_breadcrumb - 20 + * @hooked WC_Structured_Data::generate_website_data() - 30 + */ +do_action( 'woocommerce_before_main_content' ); + +?> +
+ +

+ +
+ - - + /** + * Hook: woocommerce_before_shop_loop. + * + * @hooked wc_print_notices - 10 + * @hooked woocommerce_result_count - 20 + * @hooked woocommerce_catalog_ordering - 30 + */ + do_action( 'woocommerce_before_shop_loop' ); -

+ woocommerce_product_loop_start(); - + if ( wc_get_loop_prop( 'total' ) ) { + while ( have_posts() ) { + the_post(); - - - - - - - - - - - - - - - - - - - - - - - - - woocommerce_product_loop_start( false ), 'after' => woocommerce_product_loop_end( false ) ) ) ) : ?> - - - - + do_action( 'woocommerce_shop_loop' ); + + wc_get_template_part( 'content', 'product' ); + } + } + + woocommerce_product_loop_end(); + + /** + * Hook: woocommerce_after_shop_loop. + * + * @hooked woocommerce_pagination - 10 + */ + do_action( 'woocommerce_after_shop_loop' ); +} else { + /** + * Hook: woocommerce_no_products_found. + * + * @hooked wc_no_products_found - 10 + */ + do_action( 'woocommerce_no_products_found' ); +} - +/** + * Hook: woocommerce_after_main_content. + * + * @hooked woocommerce_output_content_wrapper_end - 10 (outputs closing divs for the content) + */ +do_action( 'woocommerce_after_main_content' ); - +/** + * Hook: woocommerce_sidebar. + * + * @hooked woocommerce_get_sidebar - 10 + */ +do_action( 'woocommerce_sidebar' ); - +get_footer( 'shop' ); diff --git a/wp-content/themes/customizr-pro-child/woocommerce/auth/form-grant-access.php b/wp-content/themes/customizr-pro-child/woocommerce/auth/form-grant-access.php index c7338d7..1a58595 100644 --- a/wp-content/themes/customizr-pro-child/woocommerce/auth/form-grant-access.php +++ b/wp-content/themes/customizr-pro-child/woocommerce/auth/form-grant-access.php @@ -22,11 +22,11 @@ -

+

-

' . esc_html( $app_name ) . '', '' . esc_html( $scope ) . '' ); ?>

+

' . esc_html( $app_name ) . '', '' . esc_html( $scope ) . '' ); ?>

diff --git a/wp-content/themes/customizr-pro-child/woocommerce/loop/loop-start.php b/wp-content/themes/customizr-pro-child/woocommerce/loop/loop-start.php index 2d9c5f5..34bbd5b 100644 --- a/wp-content/themes/customizr-pro-child/woocommerce/loop/loop-start.php +++ b/wp-content/themes/customizr-pro-child/woocommerce/loop/loop-start.php @@ -13,7 +13,11 @@ * @see https://docs.woocommerce.com/document/template-structure/ * @author WooThemes * @package WooCommerce/Templates - * @version 2.0.0 + * @version 3.3.0 */ + +if ( ! defined( 'ABSPATH' ) ) { + exit; +} ?> -