File: /var/www/vhosts/uyarreklam.com.tr/httpdocs/gunun-firsatlari-template.php.tar
themes/vadimarketv4/inc/widget-paketi/gunun-firsatlari-widget/tpl/gunun-firsatlari-template.php 0000644 00000004156 15155153064 0041330 0 ustar 00 var/www/vhosts/uyarreklam.com.tr/httpdocs/wp-content <?php
if(wp_is_mobile() && $instance['mobilgizle']) {
} else {
echo '<div class="gunun-firsatlari">';
$tumulink2 = get_term_by('slug', $instance['kategori'], 'product_cat');
$tumulink = get_category_link($tumulink2->term_id);
if($instance['baslik']) {
echo '<div class="wbaslik d-flex w-100">';
echo '<div class="wh2">'.$instance['baslik'].'</div>';
echo '<div class="wl"><a href="'.$tumulink.'">'.__('Tümü','temavadisi').'<i class="icon-right-open-big"></i></a></div>';
echo '</div>';
}
if($instance['slide']) {
echo '<script>
$(document).ready(function(){
$(".'.$args['widget_id'].'.wslide").slick({
dots: false,
infinite: true,
autoplay: true,
autoplaySpeed: 5000,
speed: 300,
slidesToShow: 4,
slidesToScroll: 4,
prevArrow: \'<i class="icon-left-open-big"></i>\',
nextArrow: \'<i class="icon-right-open-big"></i>\',
responsive: [
{
breakpoint: 1024,
settings: {
slidesToShow: 4,
slidesToScroll: 4,
}
},
{
breakpoint: 768,
settings: {
slidesToShow: 2,
slidesToScroll: 2,
arrows:false
}
},
{
breakpoint: 600,
settings: {
slidesToShow: 1,
slidesToScroll: 1,
arrows:false
}
},
{
breakpoint: 480,
settings: {
slidesToShow: 1,
slidesToScroll: 1,
arrows:false
}
}
]
});
});
</script>';
echo '<div class="'.$args['widget_id'].' wslide">';
} else {
echo '<div class="row">';
}
$args['post_type'] = 'product';
$args['orderby'] = 'date';
$args['order'] = 'desc';
$args['posts_per_page'] = $instance['urunsayisi'];
$args['tax_query'] = array(array('taxonomy' => 'product_cat', 'terms' => $instance['kategori'], 'field' => 'slug'));
$loop = new WP_Query( $args );
if ( $loop->have_posts() ) {
while ( $loop->have_posts() ) : $loop->the_post();
get_template_part('/parts/wc/type1');
endwhile;
} else {
echo __( 'Gösterilecek ürün bulunamadı','temavadisi' );
}
wp_reset_postdata();
echo '</div></div>';
}
?>