magento 1出现日期格式错误的解决办法yyyy-MM-dd HH:mm:ss

2020-05-08 14:45:20 编辑:微互媒 来源:本站原创
5月5日我相信大家在用magento1的人都会遇到这样的问题,下面微互媒来教大家怎么解决这个问题。
网站打不开,看了日志,显示一连串错误代码
The error log is the following:
a:5:{i:0;s:62:"Unknown date format, neither date nor time in 'HH.mm.ss' found";i:1;s:3041:"#0 app/code/core/Zend/Date.php(2856): Zend_Date->_time('set', '00:00:00', NULL, NULL)
#1 app/code/core/Mage/Catalog/Block/Product/New.php(85): Zend_Date->setTime('00:00:00')
#2 app/code/core/Mage/Core/Block/Abstract.php(862): Mage_Catalog_Block_Product_New->_beforeToHtml()
#3 app/code/core/Mage/Core/Block/Text/List.php(43): Mage_Core_Block_Abstract->toHtml()
#4 app/code/core/Mage/Core/Block/Abstract.php(863): Mage_Core_Block_Text_List->_toHtml()
#5 app/code/core/Mage/Core/Block/Abstract.php(582): Mage_Core_Block_Abstract->toHtml()
#6 app/code/core/Mage/Core/Block/Abstract.php(526): Mage_Core_Block_Abstract->_getChildHtml('content', true)
#7 app/design/frontend/default/replica_borse/template/page/2columns-left.phtml(49): Mage_Core_Block_Abstract->getChildHtml('content')
#8 app/code/core/Mage/Core/Block/Template.php(241): include('/home/womobrsm/...')
#9 app/code/core/Mage/Core/Block/Template.php(272): Mage_Core_Block_Template->fetchView('frontend/defaul...')
#10app/code/core/Mage/Core/Block/Template.php(286): Mage_Core_Block_Template->renderView()
#11 app/code/core/Mage/Core/Block/Abstract.php(863): Mage_Core_Block_Template->_toHtml()
#12 app/code/core/Mage/Core/Model/Layout.php(555): Mage_Core_Block_Abstract->toHtml()
#13 app/code/core/Mage/Core/Controller/Varien/Action.php(390): Mage_Core_Model_Layout->getOutput()
#14 app/code/core/Mage/Cms/Helper/Page.php(137): Mage_Core_Controller_Varien_Action->renderLayout()
#15 app/code/core/Mage/Cms/Helper/Page.php(52): Mage_Cms_Helper_Page->_renderPage(Object(Mage_Cms_IndexController), 'abc')
#16 app/code/core/Mage/Cms/controllers/IndexController.php(45): Mage_Cms_Helper_Page->renderPage(Object(Mage_Cms_IndexController), 'abc')
#17 app/code/core/Mage/Core/Controller/Varien/Action.php(419): Mage_Cms_IndexController->indexAction()
#18 app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(250): Mage_Core_Controller_Varien_Action->dispatch('index')
#19 app/code/core/Mage/Core/Controller/Varien/Front.php(176): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
#20 app/code/core/Mage/Core/Model/App.php(354): Mage_Core_Controller_Varien_Front->dispatch()
#21 app/Mage.php(683): Mage_Core_Model_App->run(Array)
#22 index.php(87): Mage::run('', 'store')
#23 {main}";s:3:"url";s:1:"/";s:11:"script_name";s:10:"/index.php";s:4:"skin";s:7:"default";}
话不多说,咱们直接进入主题,看起来是相当复杂的,下面教大家最简单且暂时的解决办法
我们只要找到\ lib \ Zend \ Locale \ Format.php 这个文件,然后将所有iconv_strpos替换为strpos 网站就能访问了
访问是可以访问了,但是还会出现货币后面有#号,或;号的情况,那么我们再找到Format.php里面查找strpos后面有带#号或;号的,再改回iconv_strpos就完事了
是不是很简单?
本站文章均为微互媒网站建设摘自权威资料,书籍,或网络原创文章,如有版权纠纷或者违规问题,请即刻联系我们删除,我们欢迎您分享,引用和转载,我们谢绝直接复制和抄袭!感谢...
我们猜你喜欢