Product items are not displayed when using some widgets

This topic has 14 replies, 4 voices, and was last updated 9 months, 3 weeks ago ago by Andrew Mitchell

  • Avatar: Jose Hernan
    Jose Hernan
    Participant
    January 12, 2024 at 21:29

    Good morning, we finished the virtual store (https://perupowersports.pe/tienda) created with the XSTORE theme a few weeks ago and everything is fine. Reviewing the Elementor widgets, I noticed that in the DEPRECATED section there is the “Products” widget, which is the one we have used on the home page to show lists (slider) of the latest products for the 3 brands managed.

    Screenshot => https://iili.io/JYBdHaR.jpg

    When testing the other widgets (Products List, Products Grid, Products Carousel and Products Masonry) from XSTORE to display products, I notice that they do not show some important elements that they do load with the “Products” widget, specifically the product label (vehicle name ) and the “Buy by WhatsApp” button.

    Screenshot => https://iili.io/JYBJp6J.jpg

    The “Ajax Products Tabs” widget that we also use in a section of the home page loads correctly and displays the data that the “Products” widget also shows us.

    Screenshot => https://iili.io/JYBd93v.jpg

    Of all the widgets for XSTORE products, the one I was thinking of placing is the “Products Grid” to replace the “Products”.

    This is the code added (I’ll pass it to you privately) in the “functions.php” file of the child theme (xstore-child) that allows the display of the “product tags” in the “Products” widget, what should I do? vary on it so it can also work with the “Products Grid” widget.

    At the CSS level (style.css) I have also added some rules in the child theme (xstore-child) to change some text and background colors in the elements.

    I will appreciate your observations.

    Kind regards.

    PS: I am thinking of adding the website to CLOUDFLARE, since the loading of content is slow, especially on the home page… On mobile devices it takes a long time. What problems could arise most commonly between XSTORE and CLOUDFLARE?

    Please, contact administrator
    for this information.
    13 Answers
    Avatar: Rose Tyler
    Rose Tyler
    Support staff
    January 14, 2024 at 10:32

    Hello, Jose Hernan,

    Thank you for getting in touch with us.

    Please provide temporary wp-admin and FTP access, we will check what can be done to help you.

    To grant WP-Admin access, please proceed to create a new user account with an administrator role through your WordPress Dashboard. Once the account is established, you may securely transmit the username and password to us via the Private Content section designated for this purpose.

    For FTP access, we require the following details: FTP host, FTP username, FTP password, FTP port, and FTP encryption type. If you need assistance in creating these credentials, please reach out to your hosting provider who will guide you through the process.

    As for adding your website to Cloudflare, it can indeed help improve your site’s loading times. The most common issues that could arise when integrating Cloudflare with XSTORE are related to caching. Sometimes, Cloudflare’s caching settings can cause outdated content to be displayed or interfere with dynamic content updates. To mitigate these issues, you may need to configure Cloudflare’s caching rules carefully and ensure that dynamic content is excluded from the cache or has a shorter cache duration.
    If you decide to proceed with Cloudflare, we recommend monitoring your website closely after implementation to quickly identify and resolve any potential conflicts.

    Best Regards,
    8Theme’s Team

    Avatar: Jose Hernan
    Jose Hernan
    Participant
    January 15, 2024 at 19:20

    Good afternoon, I am sending you the requested accesses (WordPress and FTP) privately. They tell me if they can access without problems.

    Regarding CLOUDFLARE, I appreciate your recommendations, I will take a good look at the dynamic configuration.

    Greetings.

    Please contact administrator
    for this information.
    Avatar: Rose Tyler
    Rose Tyler
    Support staff
    January 16, 2024 at 09:23

    Hello, Jose Hernan,

    Thank you for wp-admin access. We can’t connect to FTP:

    Response: 	530 Login authentication failed
    Error:        	Critical error: Could not connect to server

    Please check it.

    Best Regards,
    8Theme’s Team

    Avatar: Jose Hernan
    Jose Hernan
    Participant
    January 16, 2024 at 18:02

    Good morning, perhaps the Server has restricted you due to geographical location, from what country are you going to connect?

    They tell me to enable access permissions.

    Greetings.

    Avatar: Jose Hernan
    Jose Hernan
    Participant
    January 16, 2024 at 19:41

    You can also send me privately the IP from which you plan to connect to enable entry permissions.

    Thank you.

    Avatar: Justin
    Luca Rossi
    Support staff
    January 17, 2024 at 10:32

    Hi @Jose Hernan,

    Can you please allow our IP addresses?

    Thank you so much!

    Please contact administrator
    for this information.
    Avatar: Jose Hernan
    Jose Hernan
    Participant
    January 17, 2024 at 20:36

    Good afternoon, I have already proceeded with the permissions for access of your IP to the FTP and the respective account.

    I hope you can enter without problems, let me know.

    Thank you.

    Avatar: Justin
    Luca Rossi
    Support staff
    January 18, 2024 at 08:17

    Hi @Jose Hernan,

    Here are the 2 available hooks for the Product Grid Item.

    1. after_etheme_product_grid_list_product_element_title: this hook will display the your custom custom after the product titles. The full of code is:

    
    add_action( 'after_etheme_product_grid_list_product_element_title', 'dcms_tags_item_product', 10, 0 );
    function dcms_tags_item_product() {
    	/***** if ( ! is_shop() ) return; *****/
    	global $product;
    	$product_data = $product->get_data();
    	$tag_ids = $product_data['tag_ids'];
    	if ( ! count($tag_ids) ) return;
    	print("<section class='item-tags'>");
    	foreach ($tag_ids as $tag_id){
    		$term_object = get_term_by('id', $tag_id, 'product_tag');
    		$tag_name = $term_object->name;
    		$tag_link = get_tag_link($tag_id);
    		printf("<a href='%s' title='%s'>%s</a>",$tag_link, $tag_name, $tag_name);
    	}
    	print("</section>");
    }
    

    2. etheme_product_grid_list_product_hover_element_render: we can display custom shortcode, HTML, or code within the hover content.

    3. What’s your custom code for the Whatsapp buttons? So we can help you to find the right hooks. We’ve attached the test page in Private Content Area.

    Best Regards,
    8Theme’s Team

    Please contact administrator
    for this information.
    Avatar: Jose Hernan
    Jose Hernan
    Participant
    January 19, 2024 at 20:37

    Good afternoon, I can only answer you calmly.

    First of all, thank you very much for the variants of the code that I was initially using for the “Products” widget, the one you shared with me works correctly in the new widgets that would be replacing “Products” (DEPRECATED).

    I am answering the notes:

    1.- That’s correct, now they do load the labels (vehicle types).

    2.- That’s correct, the labels can be displayed and linked.

    3.- The custom code for the WhatsApp button is a shortcode generated by the “OneClick Chat to Order” plugin, if added, it is this: [wa-order].

    Personally, I have not needed to add it, since it is automatically added to all products under the “Add to cart” button. It is a simple plugin to use in that sense, which is why it is widely used. When I installed and configured it in the theme (XStore) it was automatically added to the “Products” widget, to the “Ajax Products Tabs” widget and to the entire product list on the store pages (categories, subcategories, labels).

    A few slight observations now that I review it in detail, would be the following, I add screenshots:

    A) When showing the SKU code in the new widgets, it appears last, below the labels and the price. The order that was shown on the product sheet is:

    Category
    Qualification
    Brand
    SKU
    Price
    Label

    Is that modifiable?

    https://iili.io/JaoYMSp.png => “Poducts Grid” Widget
    https://iili.io/JaoYWHN.png => SKU on store page (product listing)
    https://iili.io/JaoYXRI.png => SKU on home page (“Products” widget)
    https://iili.io/JaoYhNt.png => SKU on the home page (“Ajax Products Tabs” widget) … In this Widget the label is no longer displayed

    B) An example of the integration of the WhatsApp button shortcode: https://perupowersports.pe/tienda/ejemplo/

    https://iili.io/JaoYjDX.png => insertion by widget “text block” and by widget “shortcode”.

    Thank you for the time and dedication in reviewing my queries.

    Kind regards.

    Avatar: Justin
    Luca Rossi
    Support staff
    January 20, 2024 at 15:54

    Hi @Jose Hernan,

    Unfortunately, the Product Grid element doesn’t have the same hooks as Products Element. To add the Whatapp button, you need to add this code:

    
    add_filter('woocommerce_loop_add_to_cart_link', 'n2t_woocommerce_loop_add_to_cart_link');
    function n2t_woocommerce_loop_add_to_cart_link($add_to_cart){
    	return $add_to_cart . do_shortcode('[wa-order]');
    }
    

    Category
    Qualification
    Brand
    SKU
    Price
    Label

    This order is fixed and we can’t change right now.

    So if you think the Product Grid element is not suitable with your custom codes, you can keep using the Products Element. Everything will be safe.

    Best Regards,
    8Theme’s Team

    Avatar: Jose Hernan
    Jose Hernan
    Participant
    January 29, 2024 at 17:56

    Good morning, sorry for responding late. Thanks for the codes and instructions provided.

    After several tests, I have decided to stick with the widget I was originally using, the “Products” (DEPRECATED). Although the other widgets (Products Grid, Products Carousel) are more updated and allow an improvement in the presentation styles, they are not as customizable in terms of codes and do not load the WhatsApp button correctly using the shortcode of the new code.

    https://iili.io/JcgQ3ve.png => The code highlighted in the red box is the button that loads on the product listing items with the new shortcode, and does not react to the plugin settings. By default, the correct operation is that of the top button, which appears next to the red “ADD TO CART” button.

    https://iili.io/JcgQ2a9.png => If a product does not have a price or stock, the new shortcode button is also displayed, but it does not work correctly since it does not open the WhatsApp application or link directly to the associated telephone number.

    I hope I don’t have any problems in the future with the “Products” (DEPRECATED) widget.

    I also thank you for your follow-up and attention to my query.

    Kind regards.

    Avatar: Justin
    Luca Rossi
    Support staff
    January 30, 2024 at 04:56

    Dear Jose Hernan,

    Thank you for your correspondence.

    Should you have any inquiries, please do not hesitate to reach out to us.

    Warm regards,
    The 8Theme Team

    Avatar: Andrew Mitchell
    Andrew Mitchell
    Support staff
    January 30, 2024 at 07:40

    Dear Jose Hernan,

    In the spirit of gratitude, we want to express our appreciation for your trust in our products. As a valued customer, your experience matters greatly. Would you consider sharing it by giving our theme a deserving 5-star rating on ThemeForest?

    Click here to share your thoughts: https://themeforest.net/downloads

    Being part of our community means a lot, and your feedback contributes immensely.

    Best Regards,
    The 8Theme Team

  • Viewing 14 results - 1 through 14 (of 14 total)

The issue related to '‘Product items are not displayed when using some widgets’' has been successfully resolved, and the topic is now closed for further responses

8theme customization service
We're using our own and third-party cookies to improve your experience and our website. Keep on browsing to accept our cookie policy.