I have a Magento 2.2 website that was moved to a new server and now when I go to the website I am presented with the below. Howeever I am not clear on what file the error exists within?? Any suggestions on how to figure out what file to go look in?
1 exception(s): Exception #0 (Magento\Framework\Config\Dom\ValidationException): Element 'head': Character content other than whitespace is not allowed because the content type is 'element-only'.
Line: 45
Best Answer
Check your xml files with head element, as it seems some of them have characters which Magento does not allow / recognize https://magento.stackexchange.com/a/197822/3566
To avoid problems like this, you can use Sublime Text editor https://www.sublimetext.com/, with
trim_trailing_white_space_on_save
parameter enabledhttp://docs.sublimetext.info/en/latest/reference/settings.html