How to Fix Your Custom Theme After Magento 2.1.0 Upgrade Breaks It
Recently we upgraded a client site from Magento 2.0.7 to Magento 2.1.0, and discovered that our custom theme broke after the upgrade.
Below is some information that we hope will help other developers who encounter a similar problem.
Software versions (before upgrade)
Apache 2.2.29
PHP 7.0.8
MySQL 5.6.25
Magento 2.0.7
and a custom Magento theme
Steps to reproduce
Follow instructions and upgrade Magento from 2.0.7 to 2.1.0 (reference: http://devdocs.magento.com/guides/v2.1/release-notes/tech_bull_21-upgrade.html)
Run “php bin/magento setup:upgrade”
Analysis
It seems, some bad left-over data on the database is corrupting layout XML processing. The layout XML extending via theme layout files are NOT applied to rendered pages.
Solution
Remove the custom theme completely, then re-install it.
At back end, “CONTENT” => “Configuration”. Replace the custom theme with the Blank theme
At back end, “CONTENT” = > “Themes”. Select the custom theme and “Delete”
(important !!)
Backup all custom theme files and directories
Remove all custom theme files and directories from app/design/frontend/
At command line, run “php bin/magento setup:upgrade”
Make sure Blank theme is active, and the custom theme is NOT listed under “CONTENT” => “Themes”
Restore the custom theme from the backup
At back end, make sure the custom theme is listed under “CONTENT” => “Themes”
At back end, “CONTENT” => “Configuration”. Set the custom theme.
At command line, run “php bin/magento setup:upgrade”
________________________ Endertech is a Los Angeles Tech Company able to provide Magento solutions for your Ecommerce Website needs. Contact us for a free consultation.