GhostManSec
Server: LiteSpeed
System: Linux premium197.web-hosting.com 4.18.0-553.54.1.lve.el8.x86_64 #1 SMP Wed Jun 4 13:01:13 UTC 2025 x86_64
User: parhudrw (1725)
PHP: 7.4.33
Disabled: NONE
Upload Files
File: /home/parhudrw/alicreates.com/wp-content/themes/essentials/woocommerce/pixfort/product-top-img.php
<?php
/**
* The template for displaying product content within loops
*
* This template can be overridden by copying it to yourtheme/woocommerce/content-product.php.
*
* HOWEVER, on occasion WooCommerce will need to update template files and you
* (the theme developer) will need to copy the new files to your theme to
* maintain compatibility. We try to do this as little as possible, but it does
* 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/
* @package WooCommerce/Templates
* @version 3.4.0
*/

defined( 'ABSPATH' ) || exit;

global $product;

// Ensure visibility.
if ( empty( $product ) || ! $product->is_visible() ) {
	return;
}
$nonce = wp_create_nonce("product_nonce");

$extra_classes = 'shadow-sm fly shadow-hover-sm rounded-lg';
if(!empty($GLOBALS['item_extra_classes'])){
    $extra_classes = $GLOBALS['item_extra_classes'];
}
?>
<li <?php wc_product_class('', $product); ?>>
	<div class="pix-product-item bg-white <?php echo esc_attr( $extra_classes ); ?> pix-p-20">
		<?php
		$image = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), 'pix-woocommerce-md' );
		?>
		<?php
		/**
		* Hook: woocommerce_before_shop_loop_item.
		*
		* @hooked woocommerce_template_loop_product_link_open - 10
		*/
		do_action( 'woocommerce_before_shop_loop_item' );
		/**
		* Hook: woocommerce_before_shop_loop_item_title.
		*
		* @hooked woocommerce_show_product_loop_sale_flash - 10
		* @hooked woocommerce_template_loop_product_thumbnail - 10
		*/
		remove_action('woocommerce_before_shop_loop_item_title', 'woocommerce_show_product_loop_sale_flash', 10); ?>
		<a href="<?php echo get_the_permalink() ?>">
			<div class="position-relative rounded-lg overflow-hidden pix-product-img-hover pix-mb-10 d-block w-100">
			<?php do_action( 'woocommerce_before_shop_loop_item_title' ); ?>
			</div>
		</a>

		<div class="pix-pt-202">

			<div class="d-flex align-items-center">
				<div class="flex-fill">
					<a href="<?php echo get_the_permalink() ?>"  class="secondary-font font-weight-bold text-heading-default p-0 align-self-center"><?php echo  do_shortcode( get_the_title() ); ?></a>
				</div>
				<?php do_action( 'pix_product_preview_btn', 'default', $post, $nonce ); ?>
			</div>
			<div class="pix-item-badges">
			<?php
			action_pixfort_product_cats();
			woocommerce_show_product_loop_sale_flash();
			?>
			</div>
		</div>
		<?php
		/**
		* Hook: woocommerce_after_shop_loop_item_title.
		*
		* @hooked woocommerce_template_loop_rating - 5
		* @hooked woocommerce_template_loop_price - 10
		*/
		remove_action('woocommerce_after_shop_loop_item_title', 'woocommerce_template_loop_rating', 5);
		remove_action('woocommerce_after_shop_loop_item_title', 'woocommerce_template_loop_price', 10);
		do_action( 'woocommerce_after_shop_loop_item_title' );
		/**
		* Hook: woocommerce_after_shop_loop_item.
		*
		* @hooked woocommerce_template_loop_product_link_close - 5
		* @hooked woocommerce_template_loop_add_to_cart - 10
		*/
		$disableDefaultAdd = true;
		if(pix_get_option('shop-default-add-cart')){
			$disableDefaultAdd = false;
		}
		if($disableDefaultAdd){
			remove_action('woocommerce_after_shop_loop_item', 'woocommerce_template_loop_add_to_cart', 10);
		}
		do_action( 'woocommerce_after_shop_loop_item' );
		$price_area = '';
		if(wc_review_ratings_enabled()&&$product->get_rating_count()>0){
			$price_area = 'pix-product-price-rating';
		}
		?>
		<div class="d-flex align-items-center pix-pt-20">
			<div class="flex-fill <?php echo esc_attr( $price_area );?>">
				<div class="pix-product-price">
					<?php woocommerce_template_loop_price(); ?>
				</div>
				<div class="pix-product-rating">
					<?php woocommerce_template_loop_rating(); ?>
				</div>
			</div>
			<?php
			if( class_exists( 'YITH_WCWL' ) ){
				?>
				<div class="pix-pl-10 align-self-stretch d-flex">
				<?php
				$like_link = admin_url('admin-ajax.php');
				$status = '';
				$like_classes = 'text-body-default';
				global $yith_wcwl;
				if(empty($yith_wcwl->details['user_id'])){
					$yith_wcwl->details['user_id'] = '';
				}
				if($yith_wcwl->is_product_in_wishlist($post->ID)){
					$status = 'remove-item';
					$like_classes = 'text-red';
				}
				?>
				<a href="#" data-wishlist-link="<?php echo esc_url($like_link); ?>" data-id="<?php echo esc_attr( $post->ID); ?>" class="pix-add-to-wishlist <?php echo esc_attr( $status); ?>"><span class="btn-icon <?php echo esc_attr( $like_classes); ?> text-18 pixicon-heart align-self-center"></span></a>
				</div>
				<?php
			}
			do_action( 'pix_product_add_to_cart_sm_btn', $post, $product, $nonce );
			?>
		</div>
	</div>
</li>