While trying to run command in CLI Magento root - php magento cron:run I get the following error message:
PHP Fatal error: Class 'IntlDateFormatter' not found in /var/www/vhosts/mrwhitewarefoh.co.uk/httpdocs/vendor/magento/framework/ObjectManager/Factory/AbstractFactory.php on line 93
When I look in the files AbstractFactory.php doesn't have a line 93
Looking online one person says it has something to do with extension=php_intl.dll (http://wdevelop.com/magento-2-fatal-error-class-intldateformatter-not-found/)
Could this be where the issue is?
Yes !! you need to enable the intl extension of php from php.ini file.
There are couple of extension which is required to enabled from php.ini for magento 2.
Here is the full Magento 2 technology stack required php extensions details - https://devdocs.magento.com/guides/v2.2/install-gde/system-requirements-tech.html
So enabled the mention extensions and it will works !!
I figured out about enabling intl soon after posting and got the cron working, now I have another problem,
I had to set:
chmod 777 -R /var/www/vhosts/mrwhitewarefoh.co.uk/httpdocs/var/*
chmod 777 -R /var/www/vhosts/mrwhitewarefoh.co.uk/httpdocs/app/*
then all cron_schedule in database go to success but still no emails, all store email and sales emails are set up and correspond with mailboxes set up on server.
I tried to test email in CLI:
echo "This is a test." | mail -s Testing firstname.lastname@example.org
but nothing came through, not sure where I should be looking now for solution.