Hi we just moved to a new host. The new host migrated our wordpress/woocommerce webstore for us.

Since the migration I am getting several errors in unrelated parts of the site regarding undefined variables, properties and indexes:

Notice: Undefined index: title in /chroot/home/trailhea/inflatablesupcanada.ca/html/wp-content/plugins/woocommerce/templates/single-product/tabs/tabs.php on line 37

Notice: Undefined index: callback in /chroot/home/trailhea/inflatablesupcanada.ca/html/wp-content/plugins/woocommerce/templates/single-product/tabs/tabs.php on line 43

Warning: call_user_func() expects parameter 1 to be a valid callback, no array or string given in /chroot/home/trailhea/inflatablesupcanada.ca/html/wp-content/plugins/woocommerce/templates/single-product/tabs/tabs.php on line 43
****These 3 errors are affecting the reviews tab but only on certain products. Some others show the reviews tab properly.

Notice: Undefined property: stdClass::$slug in /chroot/home/trailhea/inflatablesupcanada.ca/html/wp-admin/includes/class-wp-plugin-install-list-table.php on line 52
****appears in the popup window when clicking on view details for a plugin.

Notice: Undefined variable: ga_id in /chroot/home/trailhea/inflatablesupcanada.ca/html/wp-content/plugins/woocommerce-google-analytics-integration/includes/class-wc-google-analytics-js.php on line 234

Notice: Undefined variable: ga_id in /chroot/home/trailhea/inflatablesupcanada.ca/html/wp-content/plugins/woocommerce-google-analytics-integration/includes/class-wc-google-analytics-js.php on line 249
****these last 2 occasionally appears in the header of the page

Things tried so far:
-different versions of php
-tested with different theme
-tested with only woocommerce plugin active (this resolved some problems like the google analytics one but not all of them and is not really a fix..)
-Ran DELETE FROM wp_options WHERE option_name LIKE (‘%_transient_%’) as a result of reading this post: https://core.trac.wordpress.org/ticket/33330 to fix the issue on the plugin page:

All these problems are still occurring and I am out of my depth. None of these problems where occurring under the previous hosts. Support with the new hosts cannot find the issue. Woocommerce support has not been able to find the problem. Can anyone point me in the right direction as to how to solve this issue.

Read more here: Getting many Undefined variable or undefined index warnings since site was migrated to another host


Solution:

If you know the solution of this issue, please leave us a reply in Comment section, to update the question.


Wordpress related questions and answers: