Forum Replies Created

Viewing 30 posts - 151 through 180 (of 351 total)
  • Avatar: Royalty
    Royalty
    Participant
    January 25, 2017 at 17:19

    Exacetly the same bug here. I disabled all plugins except woocommerce and made a fresh and untouched install of royal version 2.9. the cart widget always shows the opened cart popup.

    Avatar: Royalty
    Royalty
    Participant
    January 20, 2017 at 17:02

    Ah ok I didnt see the second part! Thank you very much! Could you please delete the link to my testpage and the screenshot? Thank you and have a nice weekend!

    Avatar: Royalty
    Royalty
    Participant
    January 19, 2017 at 19:11

    Ok, please find them in private content. Thank you.

    Please, contact administrator
    for this information.
    Avatar: Royalty
    Royalty
    Participant
    January 19, 2017 at 18:48

    Even if I add
    $first_slide_class = ( $_i === 1 ) ? 'your-first-slide-class' : '';
    directly to theme-functions, it has no effect.

    Avatar: Royalty
    Royalty
    Participant
    January 19, 2017 at 18:45

    Thank you, I did what you said, but the change has no effect, it doesnt add the class.
    Here is the code that I added to my childtheme’s functions.php

        function etheme_create_slider($args, $slider_args = array()){//, $title = false, $shop_link = true, $slider_type = false, $items = '[[0, 1], [479,2], [619,2], [768,4],  [1200, 4], [1600, 4]]', $style = 'default'
            global $wpdb, $woocommerce_loop;
            
            $product_per_row = etheme_get_option('prodcuts_per_row');
            extract(shortcode_atts(array( 
    	        'title' => false,
    	        'shop_link' => false,
    	        'slider_type' => false,
    	        'items' => '[[0, 1], [479,2], [619,2], [768,4],  [1200, 4], [1600, 4]]',
    	        'style' => 'default',
    	        'block_id' => false
    	    ), $slider_args));
    
            $box_id = rand(1000,10000);
            $multislides = new WP_Query( $args );
            $shop_url = get_permalink(woocommerce_get_page_id('shop'));
            $class = $container_class = $title_output = '';
            if(!$slider_type) {
            	$woocommerce_loop['lazy-load'] = true;
            	$woocommerce_loop['style'] = $style;
            }
            
    
            if(!$slider_type) {
                $container_class = '';
                $class .= 'owl-carousel';
            } elseif($slider_type == 'swiper') {
                $container_class = 'et-swiper-container';
                $class .= 'swiper-wrapper';
            }
    
            if ( $multislides->have_posts() ) :
                if ($title) {
                    $title_output = '<h2 class="title"><span>'.$title.'</span></h2>';
                }   
                  echo '<div class="carousel-area '.$container_class.' slider-'.$box_id.'">';
                      echo $title_output;
                      echo '<div class="'.$class.' productCarousel">';
                            $_i=0;
                        	if($block_id && $block_id != '' && et_get_block($block_id) != '') {
                                echo '<div class="slide-item '.$slider_type.'-slide">';
                                    echo et_get_block($block_id);
                                echo '</div><!-- slide-item -->';
                        	}
                            while ($multislides->have_posts()) : $multislides->the_post();
                                $_i++;
                                $first_slide_class = ( $_i === 1 ) ? 'your-first-slide-class' : '';
                                if(class_exists('Woocommerce')) {
                                    global $product;
                                    if (!$product->is_visible()) continue; 
                                    echo '<div class="slide-item product-slide '.$slider_type.'-slide">';
                                        woocommerce_get_template_part( 'content', 'product-slider' );
                                    echo '</div><!-- slide-item -->';
                                }
    
                            endwhile; 
                      echo '</div><!-- products-slider -->'; 
                  echo '</div><!-- slider-container -->'; 
            endif;
            wp_reset_query();
            unset($woocommerce_loop['lazy-load']);
            unset($woocommerce_loop['style']);
            
            if($items != '[[0, 1], [479,2], [619,2], [768,4],  [1200, 4], [1600, 4]]') {
                $items = '[[0, '.$items['phones'].'], [479,'.$items['tablet'].'], [619,'.$items['tablet'].'], [768,'.$items['tablet'].'],  [1200, '.$items['notebook'].'], [1600, '.$items['desktop'].']]';
            } 
            if(!$slider_type) {
    	        echo '
    	
    	            <script type="text/javascript">
    	                jQuery(".slider-'.$box_id.' .productCarousel").owlCarousel({
    	                    items:4, 
    	                    lazyLoad : true,
    	                    navigation: true,
    	                    navigationText:false,
    	                    rewindNav: false,
    	                    itemsCustom: '.$items.'
    	                });
    	
    	            </script>
    	        ';
            } elseif($slider_type == 'swiper') {
    	        echo '
                    <script type="text/javascript">
                      if(jQuery(window).width() > 767) {
                          jQuery(".slider-'.$box_id.'").etFullWidth();
                          var mySwiper'.$box_id.' = new Swiper(".slider-'.$box_id.'",{
                            keyboardControl: true,
                            centeredSlides: true,
                            calculateHeight : true,
                            slidesPerView: "auto",
                            mode: "horizontal"
                          })
                      } else {
                          var mySwiper'.$box_id.' = new Swiper(".slider-'.$box_id.'",{
                            calculateHeight : true
                          })
                      }
                    
                        jQuery(function($){
                            $(".slider-'.$box_id.' .slide-item").click(function(){
                                mySwiper'.$box_id.'.swipeTo($(this).index());
                                $(".lookbook-index").removeClass("active");
                                $(this).addClass("active");
                            });
                            
                            $(".slider-'.$box_id.' .slide-item a").click(function(e){
                                if($(this).parents(".swiper-slide-active").length < 1) {
                                    e.preventDefault();
                                }
                            });
                        }, jQuery);
                    </script>
    	        ';
            }
                
        }
    Avatar: Royalty
    Royalty
    Participant
    January 17, 2017 at 16:57

    I just need to understand why this part results in these weird classes

    // Store loop count we're currently on
    if ( empty( $woocommerce_loop['loop'] ) )
    	$woocommerce_loop['loop'] = 0;
    
    // Store column count for displaying the grid
    if ( empty( $woocommerce_loop['columns'] ) )
    	$woocommerce_loop['columns'] = apply_filters( 'loop_shop_columns', 4 );
    
    // Ensure visibility
    if ( ! $product || ! $product->is_visible() )
    	return;
    
    // Increase loop count
    $woocommerce_loop['loop']++;
    
    // Extra post classes
    $classes = '';
    if ( 0 == ( $woocommerce_loop['loop'] - 1 ) % $woocommerce_loop['columns'] || 1 == $woocommerce_loop['columns'] )
    	$classes .= 'first ';
    if ( 0 == $woocommerce_loop['loop'] % $woocommerce_loop['columns'] )
    	$classes .= 'last ';

    I just want the first item in the slider to be marked with “first” or something else, thats all.

    Avatar: Royalty
    Royalty
    Participant
    January 17, 2017 at 16:55

    Or do you mean that I should use the ids that are automatically generated like slider-8637?
    Thats no solution as I need these sliders on every product page…

    Avatar: Royalty
    Royalty
    Participant
    January 17, 2017 at 16:52

    Where can I set the slider id? I dont find this option in the slider-settings…

    Avatar: Royalty
    Royalty
    Participant
    January 15, 2017 at 18:20

    No, it’s very confusing.
    If I add the shortcode [etheme_products] to a page, classes are set like this:
    1. Item class FIRST
    2. Item
    3. Item
    4. Item class LAST
    5. Item class FIRST
    […]

    But if I add the same shortcode on product description field of a product, the classes are set like this:
    1. Item
    2. Item
    3. Item class LAST
    4. Item class FIRST
    5. Item
    […]

    When I add two shortcodes like [etheme_products][etheme_products], the first slider has the classes set like my second example and the second slider has the classes set like the first example.

    I really don’t get it, its totally confusing. I would like to ignore all of these confusing classes and just find a way to style the first item of the slider, but I dont know how. :first-child doesnt work here…

    Avatar: Royalty
    Royalty
    Participant
    January 13, 2017 at 11:52

    Great, that works, thank you very much!
    Anyway, I am looking for an alternative solution now: Instead of hiding the current product, I would like to have the current product always as first item in the slider. Is this possible?
    Many thanks in advance!

    Avatar: Royalty
    Royalty
    Participant
    January 13, 2017 at 11:39

    Thank you, but I don’t want to use grid, I want to use slider…

    Avatar: Royalty
    Royalty
    Participant
    January 7, 2017 at 14:52

    Ok sorry its me again,
    also in content-product-slider.php there is this part that says that there should be 4 columns:

    // Store column count for displaying the grid
    if ( empty( $woocommerce_loop['columns'] ) )
    	$woocommerce_loop['columns'] = apply_filters( 'loop_shop_columns', 4 );

    What is this code for and how can I edit it in order to set the colums dynamically?

    Avatar: Royalty
    Royalty
    Participant
    January 7, 2017 at 14:43

    I think I found the part that causes the problem:
    In content-product-slider.php there is this part:

    // Extra post classes
    $classes = '';
    if ( 0 == ( $woocommerce_loop['loop'] - 1 ) % $woocommerce_loop['columns'] || 1 == $woocommerce_loop['columns'] )
    	$classes .= 'first ';
    if ( 0 == $woocommerce_loop['loop'] % $woocommerce_loop['columns'] )
    	$classes .= 'last ';

    When I edit it to the following, it seems to work but I dont know if this is a proper solution or if this will cause any problems…?

    // Extra post classes
    $classes = '';
    if ( 0 == ( $woocommerce_loop['loop'] - 1 ) )
    	$classes .= 'first ';
    if ( 0 == $woocommerce_loop['loop'] % $woocommerce_loop['columns'] )
    	$classes .= 'last ';
    Avatar: Royalty
    Royalty
    Participant
    January 6, 2017 at 17:35

    Hm, I really dont think its a big thing, in line 2609 of theme-functions.php there is this code:

    if(!function_exists('etheme_create_slider')) {
        function etheme_create_slider($args, $slider_args = array()){//, $title = false, $shop_link = true, $slider_type = false, $items = '[[0, 1], [479,2], [619,2], [768,4],  [1200, 4], [1600, 4]]', $style = 'default'
            global $wpdb, $woocommerce_loop;
            
            $product_per_row = etheme_get_option('prodcuts_per_row');
            extract(shortcode_atts(array( 
    	        'title' => false,
    	        'shop_link' => false,
    	        'slider_type' => false,
    	        'items' => '[[0, 1], [479,2], [619,2], [768,4],  [1200, 4], [1600, 4]]',
    	        'style' => 'default',
    	        'block_id' => false
    	    ), $slider_args));

    and I just need to know how to add
    'post__not_in' => array($postId) to the query arguments. Dont you think you can help me with this?

    Avatar: Royalty
    Royalty
    Participant
    January 6, 2017 at 17:13

    Hello Eva,
    thank you but that doesnt solve my problem. I want to automatically show all products with a specific tag on single product pages but exclude the current product. An alternative solution would be to reorder the results and always show the current product as first slide, but I think this would be even more complicated…

    Avatar: Royalty
    Royalty
    Participant
    December 14, 2016 at 08:59

    Works perfect, thank you very much!

    Avatar: Royalty
    Royalty
    Participant
    December 12, 2016 at 21:03

    Yes I know but I dont want to add to many template files into my childtheme. I always prefer to use functions.php of my childtheme for modifications. So, isn’t there a way to achieve this via functions.php?

    Avatar: Royalty
    Royalty
    Participant
    December 12, 2016 at 20:50

    Thank you very much for your soon reply! Is it possible to modify this code to use it in functions.php instead?

    Avatar: Royalty
    Royalty
    Participant
    October 15, 2016 at 11:39

    Ok I could solve it. It’s too complicated to explain in detail but it had something to do with YOAST seo plugin and breadcrumbs (your modification in etheme grabs the product title from a part in breadcrumbs and not just from the product-title, that makes it a bit complicated when using custom breadcrumbs). Sorry that I thought it was not fixed!

    Avatar: Royalty
    Royalty
    Participant
    October 15, 2016 at 10:57

    Ok, I have an idea what could cause the problem. I will check and let you know.

    Avatar: Royalty
    Royalty
    Participant
    October 15, 2016 at 08:57

    Hello Eva,
    the screenshot Jack posted (and now deleted – thank you) was taken from my official page, where I still have version 2.7.3 enabled. I uploaded the new version 2.8. to a test environment. Before I give you FTP credentials, let me tell you what I changed to make it work:
    In etheme.js line 1470, there is:

    if ($('.product_title').first().text()) {
     productName = $('.product_title').first().text();
     } else {
     productName = $('h1.title').first().text();
     }

    and I changed the code to:

    if ($('.meta-title span').first().text()) {
     productName = $('.meta-title span').first().text();
     } else {
     productName = $('h1.title').first().text();
     }

    Is it possible that the problem was only fixed for simple products? I have only variable products so I can not check it but maybe you can..

    Avatar: Royalty
    Royalty
    Participant
    October 14, 2016 at 23:50

    Its definetly not fixed, it only works because I edited etheme.js! Please delete the screenshot of my page!

    Avatar: Royalty
    Royalty
    Participant
    October 14, 2016 at 18:43

    It’s still not fixed in version 2.8. Why??

    Avatar: Royalty
    Royalty
    Participant
    August 29, 2016 at 11:52

    Ok thank you!

    Avatar: Royalty
    Royalty
    Participant
    August 29, 2016 at 10:34

    Thanks. I know that I can customize the theme using my childtheme. I just wanted to know if the specific change I made (adding the “products” class to the string in loop-start.php) could cause any problems?

    Avatar: Royalty
    Royalty
    Participant
    August 25, 2016 at 20:44

    Forget it, I made a little mistake – it works 🙂

    Avatar: Royalty
    Royalty
    Participant
    August 25, 2016 at 16:24

    The changelog of verison 2.7.3 says that this is fixed, but I just updated and the bug is still there :/

    Avatar: Royalty
    Royalty
    Participant
    August 18, 2016 at 18:05

    Hello,
    just found your answer now. I dont get any notification emails although i’ve checked to get noticed…anyway – I really dont get it. Now I deactivated all plugins, cleared the cache, reactivated them and now it works. I did this at least 5 times before without luck. Strange. I will keep an eye on this and will come back to you as if this problem happens again..

    Avatar: Royalty
    Royalty
    Participant
    August 11, 2016 at 09:49

    Ok thank you! Looking forward for the fix!

    Avatar: Royalty
    Royalty
    Participant
    August 11, 2016 at 08:58

    I use latest version of everything. All plugins and theme. I reuploaded the whole themefolder. Maybe the problem only exists for variable products. Woocommerce came up with the greyed out add to cart button just recently. Could you please check with a variable product?
    Many thanks!

  • 1 2 3 5 6 7 10 11 12
    Viewing 180 results - 151 through 180 (of 351 total)
Viewing 30 posts - 151 through 180 (of 351 total)
We're using our own and third-party cookies to improve your experience and our website. Keep on browsing to accept our cookie policy.