Divi change project category slug

How to change taxonomy urls in wordpress? Following along with this question and this one But can not get the desired outcome. The default is: example.com/project_category/%category%/ What I want is: example.com/stainless-steel-products/%category%/ I have changed the slug of the project archive so that example.com/stainless-steel-products/ is the project archive. Below is the code used to achieve that. … Read more

Undefined offset: 0 in WordPress after latest version upgrade

My WordPress powered website always worked great, however after the latest upgrade to 5.6.2 and 5.7 I have a major issue that actually breaks an important part of the website, I have seen to go through the logs and found the following error: [14-Mar-2021 00:29:32 UTC] PHP Notice: Undefined offset: 0 in /var/www/html/wp-content/plugins/tours/includes/class-tours-tour-post-type.php on line … Read more

How to add a custom field for image in “Text and Full Image(text right)” layout?

I need add another image in the standard “Text and Full Image(text right) layout” in WordPress. This layout by default has a field for an image. I located the php file that renders this page which is text-and-full-image-text-right.php Is there a way I can add a new image field in this standard layout? The Screenshot below shows you where I need to place my new image. I know how to use custom fields in a template, but not sure how to use them in the layouts/rows in the edit screen?

wc_get_product_id_by_sku() returns 0 for products added programatically via update_post_meta

I am parsing some products from XML and adding them into the database in woocommerce programmatically. SKU along with other data is saved with update_post_meta($post_id, '_sku', (string)$product->id); and is visible in the back-end. The problem is that when I try to check if there exists product with some SKU added this way programatically I always get 0.