Customization lost after recent updates (Pro)

Hi,

Few Issues after recent PRO updates:

  1. We have lost Custom Header and Custom Footer made from Builder. But after saving the custom header and footer it appeared. Though still there is issue. Sometimes our custom Header and Footer appears and sometimes its just disappears (Default Header appears which is broken as we have not customized that Default Header and Footer). Don’t know why is this happening!

  2. {{dc:woocommerce:cart_items}} not working at the front End as the Browser display as it is as “{{dc:woocommerce:cart_items}}”

  3. Menu for the mobile devices are broken. You can see at below attached screenshot.
    Mobile-Menu-broken-1

  4. We have lost some customized layouts. For example Search Template, Woocommerce’s certain Category and Tags Archive Layout.

Few links are:

https://www.hamroshringar.com/search/dr+jk1
https://www.hamroshringar.com/product-category/christmas-day-offer/

Please let us know how can we fix this.

Hoping for the solutions.

Thank You,

Bibhash Karn

Hey Bibhash,

Thanks for writing in! Please update to the latest version Pro 6.0.2 first. And then make sure to clear all your plugin caches since you have installed W3 Total Cache plugin. If still having some issues, please check this out:

And if everything is not helping, we would love to check the site. You can create a secure note in your next reply with the following info:
– Link to your site
– WP login URL
– WP username
– WP password
– WP Administrator Role
– Confirmation that we can access and make changes to your site

To know how to create a secure note, please check this out: How The Forum Works

image

Best Regards.

Hi,

Thank You for your response.

As per your suggestion, we have updated PRO theme to the latest version Pro 6.0.2. We also cleared all the caches but the issues were not solved. Also done as the steps motioned in the above link but the issues were not solved.

So please see at the secure note for the access as per required.

Hoping for the solutions.

Thank you and best regards.

Hi Bibhash,

I have checked your website WordPress Admin dashboard and found the Headers, are you having any issues getting those Headers in Cornerstone? I have also not found the issue related to the {{dc:woocommerce:cart_items}}, can you please specify the page where you are having that problem? On the other hand, I have checked the Navigation in the mobile device and found that the negative margin is set to the Right and Left and that is the reason, I would suggest you adjust the value accordingly.

Screenshot 2023-01-02 141441

I have also found the Search and other mentioned layouts in the list. Please let me know if you are still facing the issue or not.

Thanks

1 Like

Hi,

Thank you for your response.

Regarding our issues as per above:

  1. Regarding Header: There is no issues in getting Headers at the Cornerstone. Instead there is issue at the Front End with the display of Headers. Sometimes we have header (Default header in the sense when there is no customized Header’s Layout) as below image: Sometimes customized header works fine. All the header as mentioned in your above screenshot appears and works fine. As per our notice this happens when there is some changes at the website or may be when cache is cleared. We are not sure why is this happening. These customized layout were working well in the previous versions.
  2. {{dc:woocommerce:cart_items}} not working at the front End as the Browser display as it is as “{{dc:woocommerce:cart_items}}”: This is available throughout the website but it is enabled for tab and mobile devices at the Footer. Please see below image:
  3. Menu for the mobile devices are broken: There is additional background which was not at the previous version of PRO. Also we can not find the section where we can edit (remove) this background at the Cornerstone. Please suggest section at the Cornerstone for this. You can see additional background at the above screenshot at the Menu and Quick Links. Regarding Negative margin, It was working fine in Previous version of PRO though as you have mentioned we have removed all margins. Removing Negative margin made fine with the menu display.
  4. Regarding Customized layouts: As you have seen the search and layouts at the Cornerstone, but they are not visualized (implemented) at the front end of the website. We have customized layout for search and certain product’s Categories and Tags. These mentioned layouts were working fine in the previous version of PRO but with the latest PRO version these are not working. Currently default layout are being displayed instead of this customized layouts.

Please let us know if any further information is required.

Hoping for the solutions.

Thank you and best regards.
Bibhash Karn

Hey Bibhash,

  1. I can’t find the page that you’re showing in your screenshot. Kindly provide the exact URL or URLs where the issue is happening. Meanwhile, ensure your Assignments are correct.

  2. I can replicate this on my site so if this was working in Pro 5.1.5 then I suppose this is a bug. I’ll report this to our development team.

  3. The issue is not clear, kindly highlight the issue in your screenshot. It would also be best to revert your site when you’re using Pro 5.1.5 then copy your live site to a staging server and provide complete access to the staging site so we can compare Pro 5.1.5 and Pro 6.0.3 for your case.

  4. For your Search custom layout, just preview a search result. The search layout works in the frontend and the Layout builder

For the WC Archive, I only see one and it’s not working both in the layout builder and in the frontend. For cases likee this, it would also be best to revert your site when you’re using Pro 5.1.5 then copy your live site to a staging server and provide complete access to the staging site so we can compare Pro 5.1.5 and Pro 6.0.3 for your case.

image

Thanks.

Hi,

Thank you for your response.

  1. As mentioned earlier, the broken layout with the Default Header and Footer appears through out the website. Particularly this happens when the Caches are purged and also this default Header and Footer gest fixed with the custom Header and Footer when the Caches are purged once again and reappears as this process continues (This is the nature that we have found for the broken Header and Footer. We may be wrong but we have found like this). Please see below screenshot for your reference. You can see the date and time of screenshot taken at the below screenshots. This has happened after the PRO updates to 6. About the assignments, we have same assignments as it was in the PRO Pro 5.1.5. So hoping this is fine.
    Header:


    Footer:

    The URL for Home page is: https://www.hamroshringar.com/. As this is the live website we have changed the Default Header of the PRO 6.0.3 (so now you can see a little bit different header from earlier sent header in screenshot). Currently it has Main Primary Menu so that even if the broken layout appears user can see the links to navigate.

  2. {{dc:woocommerce:cart_items}} , Thank you. It was working perfectly in PRO 5.1.5. Thank you for reporting. Till then we are removing this item from our eCommerce.

  3. Please see attached below comparison image between PRO 5.15 and PRO 6.0.3. Sorry currently we don’t have staging server. We have local server instead here with PRO 5.1.5

  4. Sorry but at our side we don’t have Custom Search Layout. You can see below screenshot of search result. This is something that might be issues with point number 1 too.


    For the WC Archive: There was two but we just deleted one (For Christmas Day and New Year) of them as it was not working. We had same layout as for " International Dignified Menstruation Day". Just the condition for Product Category and Tags were different. Sorry but currently we don’t have staging server. This WC Archive layout was made in live site only so we don’t have this layout in out Local Server too.

Please let us know if any further information is required.

Thank You,
Bibhash Karn

Hey Bibhash,

For 1 and 4. I can now see the issue after trying to clear the cache of your caching plugin many times. It’s intermittent and could not be replicated at any of my test sites. The last thing we can recommend for this is that you try clearing the Style Cache in Cornerstone > Settings and try other caching plugins.

image

For 3. Please replace or rebuild the old Navigation Collapsed element with Navigation Off Canvas. The Navigation Collapsed and Navigation Layered elements don’t have the off canvas component now or the off canvas component has been separated from those elements. There is no option to control the toggle of those old Navigation elements now.

image

Thanks.

Hi,

Thank you for your response.

Thanks to know that you can see the issues at your side. It’s true, it is intermittent.

Regarding 1 and 4: As per your suggestions, we have cleared the Style Cache in Cornerstone > Settings. But even after this issues remains the same. Also we have cleared the caches from Plugins and Cloudflare. Also as per your suggestions currently we have Deactivated the W3 Total Cache (W3TC) plugins. Even though of these steps issues remains the same. You can see at the below link and screenshots. From yesterday, both Brand Pages as well as Product categories have broken Header and Footer continuously instead of intermittent.


At Cornerstone:

https://www.hamroshringar.com/product-category/health-and-beauty-products/
https://www.hamroshringar.com/product-brands/pee-safe/

Also, Search as below screenshot with default broken header and footer with no customized layout:

Regarding 3: We will do as per your suggestion and let you know how it goes.

Hoping for the solution.

Thank You,
Bibahsh Karn

Hey Bibahsh,

Now with the caching plugin deactivated, it’s your child theme that is causing the issue. I deactivated it and the header and footer is back. Note that you don’t have a layout assigned for Product Categories. You only have a layout for specific product categories.

image

image

If you want guidance as to what custom code in your child theme is causing the issue, you can subscribe to our One service.

Thanks.

Hi,

Thank you for your response. Thank you for pointing the issue.

While going through the child theme we found below functions that were causing issues.

1.Below function is used to Sort the products in “out of stock” at the end of the page. This function is important for us as “In Stock” products were prioritized and were displayed at the top of products list.

//Sort the products in “out of stock” at the end of the page
add_filter('posts_clauses', 'order_by_stock_status');
function order_by_stock_status($posts_clauses) {
global $wpdb;
// only change query on WooCommerce loops
if (is_woocommerce() && (is_shop() || is_product_category() || is_product_tag() || is_product_taxonomy())) {
    $posts_clauses['join'] .= " INNER JOIN $wpdb->postmeta istockstatus ON ($wpdb->posts.ID = istockstatus.post_id) ";
    $posts_clauses['orderby'] = " istockstatus.meta_value ASC, " . $posts_clauses['orderby'];
    $posts_clauses['where'] = " AND istockstatus.meta_key = '_stock_status' AND istockstatus.meta_value <> '' " . $posts_clauses['where'];
}
return $posts_clauses;
}

This was working well in the PRO 5.1.5 with custom Header and Footer. Is there any suggestion in which we can Sort the products in “out of stock” at the end of the page.

It’s true, we have a layout assigned for specific product categories and tags only.

2.Regarding Search Result Layout:
Below is the function taken from ACF forum and it was too working at PRO 5.1.5 with Custom Header and Footer. This was used to extend WordPress Search results to include ACF fields in search results. This function was too creating the issue with custom Header and Footer at the Search Result page.

//Extend WordPress search to include custom fields
function cf_search_join( $join ) {
global $wpdb;
if ( is_search() ) {    
    $join .=' LEFT JOIN '.$wpdb->postmeta. ' ON '. $wpdb->posts . '.ID = ' . $wpdb->postmeta . '.post_id ';
}
return $join;
}
add_filter('posts_join', 'cf_search_join' );
//Modify the search query with posts_where
function cf_search_where( $where ) {
global $pagenow, $wpdb;
if ( is_search() ) {
    $where = preg_replace(
        "/\(\s*".$wpdb->posts.".post_title\s+LIKE\s*(\'[^\']+\')\s*\)/",
        "(".$wpdb->posts.".post_title LIKE $1) OR (".$wpdb->postmeta.".meta_value LIKE $1)", $where );
}
return $where;
}
add_filter( 'posts_where', 'cf_search_where' );
//Prevent duplicates
function cf_search_distinct( $where ) {
global $wpdb;
if ( is_search() ) {
    return "DISTINCT";
}
return $where;
}
add_filter( 'posts_distinct', 'cf_search_distinct' );

Is there any suggestion in which we can Extend WordPress search to include custom ACF fields.

3.Brands (Pee Safe)
We have Custom Header for the Brand Page named (Pee Safe). We think the condition is well applied. Even tough of this, it is not getting displayed (implemented) at this particular page. We have checked with the child theme, there is no issues regarding brands. It was too working at PRO 5.1.5 with Custom Header.

You can see via below link:
https://www.hamroshringar.com/product-brands/pee-safe/

Hoping for the solutions.

Thank You,
Bibhash Karn

Hey Bibhash,

Thanks for sharing those codes. We can’t provide an answer at this time but I’ve added this case to our internal issue tracker to let our development team know that it works in Pro 5.1.5. This could be related to other WooCommerce conflicts.

For now, the only solution is to revert your site when it was using Pro 5.1.5.

Thanks.

Hi,

Thank you for your response.

Thank you for response about codes and letting it know to the development team via issue tracker.

We don’t think so as of now to revert our site to PRO 5.1.5. We can wait for the solutions from development team. Till then we are fine with the latest version of PRO.

Also, Please let us know about below issue:

Thank You,
Bibhash Karn

We’ll do, Bibhash.

Hi,

Thank you for your response.

Also, we are expecting response for below issue:

3.Brands ( Pee Safe )
We have Custom Header for the Brand Page named ( Pee Safe ). We think the condition is well applied. Even tough of this, it is not getting displayed (implemented) at this particular page. We have checked with the child theme, there is no issues regarding brands. It was too working at PRO 5.1.5 with Custom Header .

You can see via below link:
https://www.hamroshringar.com/product-brands/pee-safe/

Thank You,
Bibhash Karn

Hey Bibhash Karn,

We can’t check your custom header in Cornerstone because it has a lot of 403 errors in the console log. That being said, there could be a plugin or custom code that affects the Cornerstone loading.

I recommend the following troubleshooting procedures.

  1. TESTING FOR THEME RELATED ISSUE
  2. TESTING FOR PLUGIN CONFLICT
  3. THEME UPDATE
  4. CHILD THEME
  5. CSS/JS CUSTOMIZATION
  6. VERSION COMPATIBILITY

Hope that helps and let us know how it goes.

Hi,

Thank you for your response.

True, we also noticed the same. Thank you for the above troubleshooting procedures.

So while going through the above procedures, the plugin “LiteSpeed Cache” is causing the loading issues of Cornerstone (We have recently used this plugin). After deactivating the “LiteSpeed Cache” the cornerstone is working very well.

We have not deactivated the “LiteSpeed Cache” for you to check the Header issue as this plugin “LiteSpeed Cache” has increase our performance and rating. So kindly deactivate this plugin during test and let us know how we can solve the above Header issue.

Thank You,
Bibhash Karn

Hey Bibhash,

Please check with the provider of the LiteSpeed Cache plugin if they have an option to disable caching when you’re logged in as admin.

Also, check with them if the plugin allows excluding directories, If it’s allowed, disable caching for the cornerstone URL or directory and everthing that follows it like cornerstone/edit

Thanks.

Hi,

Thank you for your response.

Thank you for your suggestion regarding the LiteSpeed Cache plugin. On going through “LiteSpeed Cache plugin’s” forum, we found suggestion to exclude cache and related rules. We have implement excluded rules in the settings but it does not work as the issue remains the same. You can see in the below screenshots.


And

So, please provide us suggestions in this matter.

Thank you and best regards.

Hey @bibhashkarn,

I’m sorry but we cannot configure your Litespeed cache plugin. It is beyond the scope of our product support. Please reach out to the plugin developer to learn how to exlude Pro completely. It’s only them that could solve this issue.

Thanks.