Magento Error: After Theme upload on Magento 1.9 - magento-1.9

Just uploaded a new theme and now get the error. I cannot access the website as well as the backend.
Here is the log:
Trace:
#0 /home/xxxxxx/public_html/lib/Varien/Db/Statement/Pdo/Mysql.php(110): Zend_Db_Statement_Pdo->_execute(Array)
#1 /home/xxxxxx/public_html/app/code/core/Zend/Db/Statement.php(291): Varien_Db_Statement_Pdo_Mysql->_execute(Array)
#2 /home/xxxxxx/public_html/lib/Zend/Db/Adapter/Abstract.php(480): Zend_Db_Statement->execute(Array)
#3 /home/xxxxxx/public_html/lib/Zend/Db/Adapter/Pdo/Abstract.php(238): Zend_Db_Adapter_Abstract->query('SELECT `main_ta...', Array)
#4 /home/xxxxxx/public_html/lib/Varien/Db/Adapter/Pdo/Mysql.php(428): Zend_Db_Adapter_Pdo_Abstract->query('SELECT `main_ta...', Array)
#5 /home/xxxxxx/public_html/lib/Zend/Db/Adapter/Abstract.php(737): Varien_Db_Adapter_Pdo_Mysql->query('SELECT `main_ta...', Array)
#6 /home/xxxxxx/public_html/lib/Varien/Data/Collection/Db.php(734): Zend_Db_Adapter_Abstract->fetchAll('SELECT `main_ta...', Array)
#7 /home/xxxxxx/public_html/app/code/core/Mage/Core/Model/Resource/Db/Collection/Abstract.php(521): Varien_Data_Collection_Db->_fetchAll('SELECT `main_ta...', Array)
#8 /home/xxxxxx/public_html/lib/Varien/Data/Collection/Db.php(566): Mage_Core_Model_Resource_Db_Collection_Abstract->getData()
#9 /home/xxxxxx/public_html/lib/Varien/Data/Collection.php(741): Varien_Data_Collection_Db->load()
#10 /home/xxxxxx/public_html/app/code/local/Magentothem/Revslider/Helper/Data.php(617): Varien_Data_Collection->getIterator()
#11 /home/xxxxxx/public_html/app/code/local/Magentothem/Revslider/Helper/Data.php(634): Magentothem_Revslider_Helper_Data->getAllCaptionInSlide()
#12 /home/xxxxxx/public_html/app/code/local/Magentothem/Revslider/Block/Revslider.php(26): Magentothem_Revslider_Helper_Data->initCss()
#13 /home/xxxxxx/public_html/app/code/core/Mage/Core/Block/Abstract.php(919): Magentothem_Revslider_Block_Revslider->_toHtml()
#14 /home/xxxxxx/public_html/app/code/core/Mage/Core/Block/Text/List.php(43): Mage_Core_Block_Abstract->toHtml()
#15 /home/xxxxxx/public_html/app/code/core/Mage/Core/Block/Abstract.php(919): Mage_Core_Block_Text_List->_toHtml()
#16 /home/xxxxxx/public_html/app/code/core/Mage/Core/Block/Abstract.php(637): Mage_Core_Block_Abstract->toHtml()
#17 /home/xxxxxx/public_html/app/code/core/Mage/Core/Block/Abstract.php(581): Mage_Core_Block_Abstract->_getChildHtml('ma_banner', true)
#18 /home/xxxxxx/public_html/app/design/frontend/ma_optician/ma_optician4/template/page/2columns-right.phtml(47): Mage_Core_Block_Abstract->getChildHtml('ma_banner')
#19 /home/xxxxxx/public_html/app/code/core/Mage/Core/Block/Template.php(241): include('/home/xxxxxx/...')
#20 /home/xxxxxx/public_html/app/code/core/Mage/Core/Block/Template.php(272): Mage_Core_Block_Template->fetchView('frontend/ma_opt...')
#21 /home/xxxxxx/public_html/app/code/core/Mage/Core/Block/Template.php(286): Mage_Core_Block_Template->renderView()
#22 /home/xxxxxx/public_html/app/code/core/Mage/Core/Block/Abstract.php(919): Mage_Core_Block_Template->_toHtml()
#23 /home/xxxxxx/public_html/app/code/core/Mage/Core/Model/Layout.php(555): Mage_Core_Block_Abstract->toHtml()
#24 /home/xxxxxx/public_html/app/code/core/Mage/Core/Controller/Varien/Action.php(390): Mage_Core_Model_Layout->getOutput()
#25 /home/xxxxxx/public_html/app/code/core/Mage/Cms/Helper/Page.php(137): Mage_Core_Controller_Varien_Action->renderLayout()
#26 /home/xxxxxx/public_html/app/code/core/Mage/Cms/Helper/Page.php(52): Mage_Cms_Helper_Page->_renderPage(Object(Mage_Cms_IndexController), 'ma_optician4_ho...')
#27 /home/xxxxxx/public_html/app/code/core/Mage/Cms/controllers/IndexController.php(45): Mage_Cms_Helper_Page->renderPage(Object(Mage_Cms_IndexController), 'ma_optician4_ho...')
#28 /home/xxxxxx/public_html/app/code/core/Mage/Core/Controller/Varien/Action.php(418): Mage_Cms_IndexController->indexAction()
#29 /home/xxxxxx/public_html/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(250): Mage_Core_Controller_Varien_Action->dispatch('index')
#30 /home/xxxxxx/public_html/app/code/core/Mage/Core/Controller/Varien/Front.php(172): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
#31 /home/xxxxxx/public_html/app/code/core/Mage/Core/Model/App.php(354): Mage_Core_Controller_Varien_Front->dispatch()
#32 /home/xxxxxx/public_html/app/Mage.php(684): Mage_Core_Model_App->run(Array)
#33 /home/xxxxxx/public_html/index.php(87): Mage::run('', 'store')
#34 {main}
I did this but it didn't resolve the issue.
Navigate to the "errors" folder.
Change local.xml.sample to local.xml
You should now see a new list of crazy errors all over the Magento page - this is okay.
Open magento/lib/Zend/Cache/Backend/File.php and look for:
protected $_options = array(
'cache_dir' => 'null',
Change it to:
protected $_options = array(
'cache_dir' => 'tmp/',
Save it.
Now the final step is to go create a tmp folder in the root Magento folder.
Any more pointers on what's wrong here?
Thank you.

You have any remaned localxxx.xml if it is there, just delete and clear your cache

Related

Version 1.35: Fatal exception of type MWException Error, The code that appears is:

Anyone know what I'm supposed to do?
[cb49891230242084931e4968] /index.php?title=%D7%99%D7%97%D7%99%D7%93%D7%94:%D7%AA%D7%91%D7%A0%D7%99%D7%AA_%D7%9E%D7%99%D7%93%D7%A2&action=submit MWException from line 95 of /home/u657493073/domains/tzefunotwiki.com/public_html/extensions/Scribunto/includes/engines/LuaStandalone/LuaStandaloneInterpreter.php: The lua binary (/home/u657493073/domains/tzefunotwiki.com/public_html/extensions/Scribunto/includes/engines/LuaStandalone/binaries/lua5_1_5_linux_64_generic/lua) is not executable.
Backtrace:
#0 /home/u657493073/domains/tzefunotwiki.com/public_html/extensions/Scribunto/includes/engines/LuaStandalone/LuaStandaloneEngine.php(104): Scribunto_LuaStandaloneInterpreter->__construct(Scribunto_LuaStandaloneEngine, array)
#1 /home/u657493073/domains/tzefunotwiki.com/public_html/extensions/Scribunto/includes/engines/LuaCommon/LuaEngine.php(120): Scribunto_LuaStandaloneEngine->newInterpreter()
#2 /home/u657493073/domains/tzefunotwiki.com/public_html/extensions/Scribunto/includes/engines/LuaStandalone/LuaStandaloneEngine.php(16): Scribunto_LuaEngine->load()
#3 /home/u657493073/domains/tzefunotwiki.com/public_html/extensions/Scribunto/includes/engines/LuaCommon/LuaEngine.php(223): Scribunto_LuaStandaloneEngine->load()
#4 /home/u657493073/domains/tzefunotwiki.com/public_html/extensions/Scribunto/includes/engines/LuaCommon/LuaModule.php(38): Scribunto_LuaEngine->getInterpreter()
#5 /home/u657493073/domains/tzefunotwiki.com/public_html/extensions/Scribunto/includes/engines/LuaCommon/LuaModule.php(25): Scribunto_LuaModule->getInitChunk()
#6 /home/u657493073/domains/tzefunotwiki.com/public_html/extensions/Scribunto/includes/common/ScribuntoEngineBase.php(193): Scribunto_LuaModule->validate()
#7 /home/u657493073/domains/tzefunotwiki.com/public_html/extensions/Scribunto/includes/common/ScribuntoContent.php(35): ScribuntoEngineBase->validate(string, string)
#8 /home/u657493073/domains/tzefunotwiki.com/public_html/extensions/Scribunto/includes/common/Hooks.php(366): ScribuntoContent->validate(Title)
#9 /home/u657493073/domains/tzefunotwiki.com/public_html/includes/HookContainer/HookContainer.php(320): ScribuntoHooks::validateScript(DerivativeContext, ScribuntoContent, Status, string, User, boolean)
#10 /home/u657493073/domains/tzefunotwiki.com/public_html/includes/HookContainer/HookContainer.php(131): MediaWiki\HookContainer\HookContainer->callLegacyHook(string, array, array, array)
#11 /home/u657493073/domains/tzefunotwiki.com/public_html/includes/HookContainer/HookRunner.php(1529): MediaWiki\HookContainer\HookContainer->run(string, array)
#12 /home/u657493073/domains/tzefunotwiki.com/public_html/includes/EditPage.php(1903): MediaWiki\HookContainer\HookRunner->onEditFilterMergedContent(DerivativeContext, ScribuntoContent, Status, string, User, boolean)
#13 /home/u657493073/domains/tzefunotwiki.com/public_html/includes/EditPage.php(2231): EditPage->runPostMergeFilters(ScribuntoContent, Status, User)
#14 /home/u657493073/domains/tzefunotwiki.com/public_html/includes/EditPage.php(1723): EditPage->internalAttemptSave(NULL, boolean)
#15 /home/u657493073/domains/tzefunotwiki.com/public_html/includes/EditPage.php(680): EditPage->attemptSave(NULL)
#16 /home/u657493073/domains/tzefunotwiki.com/public_html/includes/actions/EditAction.php(71): EditPage->edit()
#17 /home/u657493073/domains/tzefunotwiki.com/public_html/includes/actions/SubmitAction.php(38): EditAction->show()
#18 /home/u657493073/domains/tzefunotwiki.com/public_html/includes/MediaWiki.php(527): SubmitAction->show()
#19 /home/u657493073/domains/tzefunotwiki.com/public_html/includes/MediaWiki.php(313): MediaWiki->performAction(Article, Title)
#20 /home/u657493073/domains/tzefunotwiki.com/public_html/includes/MediaWiki.php(940): MediaWiki->performRequest()
#21 /home/u657493073/domains/tzefunotwiki.com/public_html/includes/MediaWiki.php(543): MediaWiki->main()
#22 /home/u657493073/domains/tzefunotwiki.com/public_html/index.php(53): MediaWiki->run()
#23 /home/u657493073/domains/tzefunotwiki.com/public_html/index.php(46): wfIndexMain()
#24 {main}
תפריט ניווט
Try making the Lua file executable: sudo chmod +x /home/u657493073/domains/tzefunotwiki.com/public_html/extensions/Scribunto/includes/engines/LuaStandalone/binaries/lua5_1_5_linux_64_generic/lua.

Exception 'ReflectionException' with message 'Class ingelby\toolbox\helpers\PublicIdBehavior does not exist' in yii2 advance

i am getting this error.
Exception 'ReflectionException' with message 'Class ingelby\toolbox\helpers\PublicIdBehavior does not exist'
in D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\di\Container.php:428
Stack trace:
#0 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\di\Container.php(428): ReflectionClass->__construct('ingelby\\toolbox...')
#1 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\di\Container.php(364): yii\di\Container->getDependencies('ingelby\\toolbox...')
#2 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\di\Container.php(156): yii\di\Container->build('ingelby\\toolbox...', Array, Array)
#3 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\BaseYii.php(349): yii\di\Container->get('ingelby\\toolbox...', Array, Array)
#4 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\base\Component.php(750): yii\BaseYii::createObject(Array)
#5 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\base\Component.php(734): yii\base\Component->attachBehaviorInternal(2, Array)
#6 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\base\Component.php(603): yii\base\Component->ensureBehaviors()
#7 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\db\BaseActiveRecord.php(925): yii\base\Component->trigger('init')
#8 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\base\BaseObject.php(109): yii\db\BaseActiveRecord->init()
#9 [internal function]: yii\base\BaseObject->__construct(Array)
#10 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\di\Container.php(375): ReflectionClass->newInstanceArgs(Array)
#11 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\di\Container.php(156): yii\di\Container->build('frontend\\models...', Array, Array)
#12 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\BaseYii.php(345): yii\di\Container->get('frontend\\models...', Array)
#13 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\base\StaticInstanceTrait.php(37): yii\BaseYii::createObject('frontend\\models...')
#14 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\db\ActiveQuery.php(447): yii\base\Model::instance()
#15 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\db\ActiveQuery.php(146): yii\db\ActiveQuery->buildJoinWith()
#16 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\db\QueryBuilder.php(227): yii\db\ActiveQuery->prepare(Object(yii\db\mysql\QueryBuilder))
#17 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\db\ActiveQuery.php(316): yii\db\QueryBuilder->build(Object(yii\db\ActiveQuery))
#18 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\db\Query.php(237): yii\db\ActiveQuery->createCommand(Object(yii\db\Connection))
#19 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\db\ActiveQuery.php(133): yii\db\Query->all(NULL)
#20 D:\xamppnew\htdocs\nfsp\frontend\models\Event.php(86): yii\db\ActiveQuery->all()
#21 D:\xamppnew\htdocs\nfsp\frontend\controllers\SiteController.php(212): frontend\models\Event::getEvents(Array, 50976)
#22 [internal function]: frontend\controllers\SiteController->actionIndex()
#23 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\base\InlineAction.php(57): call_user_func_array(Array, Array)
#24 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\base\Controller.php(157): yii\base\InlineAction->runWithParams(Array)
#25 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\base\Module.php(528): yii\base\Controller->runAction('', Array)
#26 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\web\Application.php(103): yii\base\Module->runAction('', Array)
#27 D:\xamppnew\htdocs\nfsp\vendor\yiisoft\yii2\base\Application.php(386): yii\web\Application->handleRequest(Object(yii\web\Request))
#28 D:\xamppnew\htdocs\nfsp\frontend\web\index.php(18): yii\base\Application->run()
#29 {main}
please help me to solve this problem.
It looks like you are missing a package in a folder vendor.
Try to execute command "composer install".
if it doesn’t help, show please composer.

Changing Magento database

I have installed magento 1.7 with the database name magento1.7 and now I want to replace this with current live dump with the name magento.
I have changed dbnames in local.xml and config.xml,cleared cache and other things in magento. But now I am getting the below error when i load my magento local.
SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '921923' for key 'PRIMARY'
Trace:
#0 /Applications/XAMPP/xamppfiles/htdocs/magento/lib/Varien/Db/Statement/Pdo/Mysql.php(110): Zend_Db_Statement_Pdo->_execute(Array)
#1 /Applications/XAMPP/xamppfiles/htdocs/magento/lib/Zend/Db/Statement.php(300): Varien_Db_Statement_Pdo_Mysql->_execute(Array)
#2 /Applications/XAMPP/xamppfiles/htdocs/magento/lib/Zend/Db/Adapter/Abstract.php(479): Zend_Db_Statement->execute(Array)
#3 /Applications/XAMPP/xamppfiles/htdocs/magento/lib/Zend/Db/Adapter/Pdo/Abstract.php(238): Zend_Db_Adapter_Abstract->query('INSERT INTO `lo...', Array)
#4 /Applications/XAMPP/xamppfiles/htdocs/magento/lib/Varien/Db/Adapter/Pdo/Mysql.php(419): Zend_Db_Adapter_Pdo_Abstract->query('INSERT INTO `lo...', Array)
#5 /Applications/XAMPP/xamppfiles/htdocs/magento/lib/Zend/Db/Adapter/Abstract.php(574): Varien_Db_Adapter_Pdo_Mysql->query('INSERT INTO `lo...', Array)
#6 /Applications/XAMPP/xamppfiles/htdocs/magento/app/code/core/Mage/Log/Model/Resource/Visitor.php(174): Zend_Db_Adapter_Abstract->insert('log_visitor_inf...', Array)
#7 /Applications/XAMPP/xamppfiles/htdocs/magento/app/code/core/Mage/Log/Model/Resource/Visitor.php(108): Mage_Log_Model_Resource_Visitor->_saveVisitorInfo(Object(Mage_Log_Model_Visitor))
#8 /Applications/XAMPP/xamppfiles/htdocs/magento/app/code/core/Mage/Core/Model/Resource/Db/Abstract.php(463): Mage_Log_Model_Resource_Visitor->_afterSave(Object(Mage_Log_Model_Visitor))
#9 /Applications/XAMPP/xamppfiles/htdocs/magento/app/code/core/Mage/Core/Model/Abstract.php(318): Mage_Core_Model_Resource_Db_Abstract->save(Object(Mage_Log_Model_Visitor))
#10 /Applications/XAMPP/xamppfiles/htdocs/magento/app/code/core/Mage/Log/Model/Visitor.php(167): Mage_Core_Model_Abstract->save()
#11 /Applications/XAMPP/xamppfiles/htdocs/magento/app/code/core/Mage/Core/Model/App.php(1338): Mage_Log_Model_Visitor->initByRequest(Object(Varien_Event_Observer))
#12 /Applications/XAMPP/xamppfiles/htdocs/magento/app/code/core/Mage/Core/Model/App.php(1317): Mage_Core_Model_App->_callObserverMethod(Object(Mage_Log_Model_Visitor), 'initByRequest', Object(Varien_Event_Observer))
#13 /Applications/XAMPP/xamppfiles/htdocs/magento/app/Mage.php(447): Mage_Core_Model_App->dispatchEvent('controller_acti...', Array)
#14 /Applications/XAMPP/xamppfiles/htdocs/magento/app/code/core/Mage/Core/Controller/Varien/Action.php(528): Mage::dispatchEvent('controller_acti...', Array)
#15 /Applications/XAMPP/xamppfiles/htdocs/magento/app/code/core/Mage/Core/Controller/Front/Action.php(64): Mage_Core_Controller_Varien_Action->preDispatch()
#16 /Applications/XAMPP/xamppfiles/htdocs/magento/app/code/core/Mage/Core/Controller/Varien/Action.php(408): Mage_Core_Controller_Front_Action->preDispatch()
#17 /Applications/XAMPP/xamppfiles/htdocs/magento/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(250): Mage_Core_Controller_Varien_Action->dispatch('index')
#18 /Applications/XAMPP/xamppfiles/htdocs/magento/app/code/core/Mage/Core/Controller/Varien/Front.php(176): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
#19 /Applications/XAMPP/xamppfiles/htdocs/magento/app/code/core/Mage/Core/Model/App.php(354): Mage_Core_Controller_Varien_Front->dispatch()
#20 /Applications/XAMPP/xamppfiles/htdocs/magento/app/Mage.php(683): Mage_Core_Model_App->run(Array)
#21 /Applications/XAMPP/xamppfiles/htdocs/magento/index.php(87): Mage::run('', 'store')
I searched in the log tables for the value "921923" but couldn't able to find any match. Can someone help/guide me to resolve this issue?
SET FOREIGN_KEY_CHECKS=0;
this then import and delete all value in log_visitor_inf.. tables then its run your website. Delete this folder var then check the website.

Large list of search filter errors encountered

I'm having an issue with the search filter, for some reason when I select the filters, I get a page with error codes all over:
There has been an error processing your request
You cannot define a correlation name color_idx more than once
Trace:
#0 /home/oembarga/public_html/lib/Varien/Db/Select.php(281): Zend_Db_Select->_join('inner join', Array, 'color_idx.entit...',
Array, NULL)
#1 /home/oembarga/public_html/lib/Zend/Db/Select.php(336): Varien_Db_Select->_join('inner join', Array, 'color_idx.entit...',
Array, NULL)
#2 /home/oembarga/public_html/lib/Zend/Db/Select.php(315): Zend_Db_Select->joinInner(Array, 'color_idx.entit...', Array, NULL)
#3 /home/oembarga/public_html/app/code/core/Mage/Catalog/Model/Resource/Layer/Filter/Attribute.php(70):
Zend_Db_Select->join(Array, 'color_idx.entit...', Array)
#4 /home/oembarga/public_html/app/code/core/Mage/Catalog/Model/Layer/Filter/Attribute.php(94): Mage_Catalog_Model_Resource_Layer_Filter_Attribute->applyFilterToCollection(Object(Mage_Catalog_Model_Layer_Filter_Attribute),
'56')
#5 /home/oembarga/public_html/app/code/core/Mage/Catalog/Block/Layer/Filter/Abstract.php(91):
Mage_Catalog_Model_Layer_Filter_Attribute->apply(Object(Mage_Core_Controller_Request_Http),
Object(Mage_Catalog_Block_Layer_Filter_Attribute))
#6 /home/oembarga/public_html/app/code/core/Mage/Catalog/Block/Layer/Filter/Abstract.php(73):
Mage_Catalog_Block_Layer_Filter_Abstract->_initFilter()
#7 /home/oembarga/public_html/app/code/core/Mage/Catalog/Block/Layer/View.php(136):
Mage_Catalog_Block_Layer_Filter_Abstract->init()
#8 /home/oembarga/public_html/app/code/core/Mage/Core/Block/Abstract.php(293):
Mage_Catalog_Block_Layer_View->_prepareLayout()
#9 /home/oembarga/public_html/app/code/core/Mage/Core/Model/Layout.php(456):
Mage_Core_Block_Abstract->setLayout(Object(Codnitive_Extifcon_Model_Core_Layout))
#10 /home/oembarga/public_html/app/code/core/Mage/Core/Model/Layout.php(472):
Mage_Core_Model_Layout->createBlock('catalog/layer_v...',
'catalog.leftnav')
#11 /home/oembarga/public_html/app/code/core/Mage/Core/Model/Layout.php(239):
Mage_Core_Model_Layout->addBlock('catalog/layer_v...',
'catalog.leftnav')
#12 /home/oembarga/public_html/app/code/core/Mage/Core/Model/Layout.php(205):
Mage_Core_Model_Layout->_generateBlock(Object(Mage_Core_Model_Layout_Element),
Object(Mage_Core_Model_Layout_Element))
#13 /home/oembarga/public_html/app/code/core/Mage/Core/Model/Layout.php(210):
Mage_Core_Model_Layout->generateBlocks(Object(Mage_Core_Model_Layout_Element))
#14 /home/oembarga/public_html/app/code/core/Mage/Core/Controller/Varien/Action.php(344):
Mage_Core_Model_Layout->generateBlocks()
#15 /home/oembarga/public_html/app/code/core/Mage/Cms/Helper/Page.php(113):
Mage_Core_Controller_Varien_Action->generateLayoutBlocks()
#16 /home/oembarga/public_html/app/code/core/Mage/Cms/Helper/Page.php(52):
Mage_Cms_Helper_Page->_renderPage(Object(Unirgy_DropshipMicrositePro_IndexController),
'default-microsi...')
#17 /home/oembarga/public_html/app/code/community/Unirgy/DropshipMicrositePro/controllers/IndexController.php(33):
Mage_Cms_Helper_Page->renderPage(Object(Unirgy_DropshipMicrositePro_IndexController), 'default-microsi...')
#18 /home/oembarga/public_html/app/code/core/Mage/Core/Controller/Varien/Action.php(418):
Unirgy_DropshipMicrositePro_IndexController->landingPageAction()
#19 /home/oembarga/public_html/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(250):
Mage_Core_Controller_Varien_Action->dispatch('landingPage')
#20 /home/oembarga/public_html/app/code/core/Mage/Core/Controller/Varien/Front.php(172):
Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
#21 /home/oembarga/public_html/app/code/core/Mage/Core/Model/App.php(354):
Mage_Core_Controller_Varien_Front->dispatch()
#22 /home/oembarga/public_html/app/Mage.php(684): Mage_Core_Model_App->run(Array)
#23 /home/oembarga/public_html/index.php(88): Mage::run('', 'store')
#24 {main}

SQLSTATE[HY000]: General error: 2006 MySQL server has gone away - What to do?

Here is what I get and I don't know what to do....
There has been an error processing your request
SQLSTATE[HY000]: General error: 2006 MySQL server has gone away
Trace:
#0 /home/autobadges/public_html/stangcenter.com/lib/Zend/Db/Statement.php(300): Zend_Db_Statement_Pdo->_execute(Array)
#1 /home/autobadges/public_html/stangcenter.com/lib/Zend/Db/Adapter/Abstract.php(479): Zend_Db_Statement->execute(Array)
#2 /home/autobadges/public_html/stangcenter.com/lib/Zend/Db/Adapter/Pdo/Abstract.php(238): Zend_Db_Adapter_Abstract->query('SELECT `main_ta...', Array)
#3 /home/autobadges/public_html/stangcenter.com/lib/Varien/Db/Adapter/Pdo/Mysql.php(333): Zend_Db_Adapter_Pdo_Abstract->query('SELECT `main_ta...', Array)
#4 /home/autobadges/public_html/stangcenter.com/lib/Zend/Db/Adapter/Abstract.php(734): Varien_Db_Adapter_Pdo_Mysql->query(Object(Varien_Db_Select), Array)
#5 /home/autobadges/public_html/stangcenter.com/lib/Varien/Data/Collection/Db.php(783): Zend_Db_Adapter_Abstract->fetchAll(Object(Varien_Db_Select), Array)
#6 /home/autobadges/public_html/stangcenter.com/lib/Varien/Data/Collection/Db.php(696): Varien_Data_Collection_Db->_fetchAll(Object(Varien_Db_Select))
#7 /home/autobadges/public_html/stangcenter.com/lib/Varien/Data/Collection/Db.php(617): Varien_Data_Collection_Db->getData()
#8 /home/autobadges/public_html/stangcenter.com/app/code/core/Mage/Adminhtml/Block/Catalog/Product/Edit/Tabs.php(57): Varien_Data_Collection_Db->load()
#9 /home/autobadges/public_html/stangcenter.com/app/code/core/Mage/Core/Block/Abstract.php(223): Mage_Adminhtml_Block_Catalog_Product_Edit_Tabs->_prepareLayout()
#10 /home/autobadges/public_html/stangcenter.com/app/code/core/Mage/Core/Model/Layout.php(430): Mage_Core_Block_Abstract->setLayout(Object(Mage_Core_Model_Layout))
#11 /home/autobadges/public_html/stangcenter.com/app/code/core/Mage/Core/Model/Layout.php(446): Mage_Core_Model_Layout->createBlock('adminhtml/catal...', 'product_tabs')
#12 /home/autobadges/public_html/stangcenter.com/app/code/core/Mage/Core/Model/Layout.php(238): Mage_Core_Model_Layout->addBlock('adminhtml/catal...', 'product_tabs')
#13 /home/autobadges/public_html/stangcenter.com/app/code/core/Mage/Core/Model/Layout.php(204): Mage_Core_Model_Layout->_generateBlock(Object(Mage_Core_Model_Layout_Element), Object(Mage_Core_Model_Layout_Element))
#14 /home/autobadges/public_html/stangcenter.com/app/code/core/Mage/Core/Model/Layout.php(209): Mage_Core_Model_Layout->generateBlocks(Object(Mage_Core_Model_Layout_Element))
#15 /home/autobadges/public_html/stangcenter.com/app/code/core/Mage/Core/Controller/Varien/Action.php(343): Mage_Core_Model_Layout->generateBlocks()
#16 /home/autobadges/public_html/stangcenter.com/app/code/core/Mage/Core/Controller/Varien/Action.php(270): Mage_Core_Controller_Varien_Action->generateLayoutBlocks()
#17 /home/autobadges/public_html/stangcenter.com/app/code/core/Mage/Adminhtml/Controller/Action.php(263): Mage_Core_Controller_Varien_Action->loadLayout(Array, true, true)
#18 /home/autobadges/public_html/stangcenter.com/app/code/core/Mage/Adminhtml/controllers/Catalog/ProductController.php(246): Mage_Adminhtml_Controller_Action->loadLayout(Array)
#19 /home/autobadges/public_html/stangcenter.com/app/code/core/Mage/Core/Controller/Varien/Action.php(418): Mage_Adminhtml_Catalog_ProductController->editAction()
#20 /home/autobadges/public_html/stangcenter.com/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(253): Mage_Core_Controller_Varien_Action->dispatch('edit')
#21 /home/autobadges/public_html/stangcenter.com/app/code/core/Mage/Core/Controller/Varien/Front.php(176): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
#22 /home/autobadges/public_html/stangcenter.com/app/code/core/Mage/Core/Model/App.php(340): Mage_Core_Controller_Varien_Front->dispatch()
#23 /home/autobadges/public_html/stangcenter.com/app/Mage.php(627): Mage_Core_Model_App->run(Array)
#24 /home/autobadges/public_html/stangcenter.com/index.php(80): Mage::run('', 'store')
#25 {main}
write your zend query in a try block
and
catch the exception
Zend_Db_Statement_Mysqli_Exception (check which one you are using 'mysql' or 'mysqli' or 'PDO') in the exception catch code just call {model}->getDefaultAdapter()->closeConnection() and then again call the zend query you have got.
this should solve your problem.
NOTE: Below code is just for reference and should not be used as it is (may have error in it).
try
{
$user = {model}->fetchRow(array('user_id = ?' => $senderid));
}
catch(Zend_Db_Statement_Mysqli_Exception $zenddbmysqliexc)
{
if(stristr($zenddbmysqliexc->getMessage(), 'MySQL server has gone away'))
{
{model}->getDefaultAdapter()->closeConnection();
$user = {model}->fetchRow(array('user_id = ?' => $senderid));
}
}