Jump to content

Please help errors with CMS after upgrading from 1.6.0.11 to 1.6.0.13


Recommended Posts

Hello,

 

I am not new to Prestashop, but new to posting in the forumn.

 

I am usually pretty good about finding answers to all my problems by reading all the amazing people's solutions posted to help others out.

 

I started the upgrade with the 1 click upgrade module and didn't realize I was so tired and nodded off. When I woke up it said the upgrade was complete. Everything worked as far as I can see except the top menu which I just uninstalled and reinstalled and works now and all my CMS pages are empty and everytime I retype all the information in I get the following error.

 

[PrestaShopDatabaseException]

Unknown column 'id_shop' in 'where clause'

SELECT * FROM `ps_cms_category_lang`

                                                             WHERE `id_cms_category` = 1 AND `id_shop` = 1

at line 646 in file classes/db/Db.php

641.                   WebserviceRequest::getInstance()->setError(500, '

 '.$this->getMsgError().'. From '.(isset($dbg[3]['class']) ? $dbg[3]['class'] : '').'->'.$dbg[3]['function'].'() Query was : '.$sql, 97);

642.           }

643.           elseif (_PS_DEBUG_SQL_ && $errno && !defined('PS_INSTALLATION_IN_PROGRESS'))

644.           {

645.                   if ($sql)

646.                           throw new PrestaShopDatabaseException($this->getMsgError().'<br /><br /><pre>'.$sql.'</pre>');

647.                   throw new PrestaShopDatabaseException($this->getMsgError());

648.           }

649.    }

650.

651.    /**

  • DbCore->displayError - [line 340 - classes/db/Db.php] - [1 Arguments]
  • DbCore->query - [line 516 - classes/db/Db.php] - [1 Arguments]
  • DbCore->executeS - [line 240 - classes/ObjectModel.php] - [1 Arguments]
  • ObjectModelCore->__construct - [line 43 - controllers/admin/AdminCmsContentController.php] - [1 Arguments]
  • AdminCmsContentControllerCore->__construct - [line 135 - classes/controller/Controller.php] - [2 Arguments]
  • ControllerCore::getController - [line 366 - classes/Dispatcher.php] - [1 Arguments]
  • DispatcherCore->dispatch - [line 54 - admin/index.php]

and can not save it.

 

I rolled back the database from both my perfect backup from phpadmin and also the one that prestashop does when you upgrade. It rolled back everything but this issue. A couple days later 14 came out and I upgraded to that crossing my fingers it would fix it, but unfortuneately I didn't. So now I am desperate!!

 

I am praying there is an easy solution to my problem because it takes me way to long to do everything all over again, plus I already lost all my customers and orders from the 1.5 to the 1.6 upgrade and can't afford to lose all the new informaton again.

 

I thank anyone in advance for any help you can offer.

 

Tina

www.climaticmoments.com

 

 

Link to comment
Share on other sites

Hello Nemo,

 

Thank you so much for taking the time to help me.

 

I pasted controllers/admin/AdminCmsContentController.php below with line 43 in red.

/*
* 2007-2015 PrestaShop
*
* NOTICE OF LICENSE
*
* This source file is subject to the Open Software License (OSL 3.0)
* that is bundled with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://opensource.org/licenses/osl-3.0.php
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to [email protected] so we can send you a copy immediately.
*
* DISCLAIMER
*
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
* versions in the future. If you wish to customize PrestaShop for your
* needs please refer to http://www.prestashop.com for more information.
*
*  @author PrestaShop SA <[email protected]>
*  @copyright  2007-2015 PrestaShop SA
*  @license    http://opensource.org/licenses/osl-3.0.php  Open Software License (OSL 3.0)
*  International Registered Trademark & Property of PrestaShop SA
*/

class AdminCmsContentControllerCore extends AdminController
{
    /** @var object adminCMSCategories() instance */
    protected $admin_cms_categories;

    /** @var object adminCMS() instance */
    protected $admin_cms;

    /** @var object Category() instance for navigation*/
    protected static $category = null;

    public function __construct()
    {
        $this->bootstrap = true;
        /* Get current category */
        $id_cms_category = (int)Tools::getValue('id_cms_category', Tools::getValue('id_cms_category_parent', 1));
        self::$category = new CMSCategory($id_cms_category);
        if (!Validate::isLoadedObject(self::$category))
            die('Category cannot be loaded');

        $this->table = 'cms';
        $this->className = 'CMS';
                $this->bulk_actions = array(
            'delete' => array(
                'text' => $this->l('Delete selected'),
                'confirm' => $this->l('Delete selected items?'),
                'icon' => 'icon-trash'
            )
        );
        $this->admin_cms_categories = new AdminCmsCategoriesController();
        $this->admin_cms_categories->init();
        $this->admin_cms = new AdminCmsController();
        $this->admin_cms->init();

        parent::__construct();
    }

    /**
     * Return current category
     *
     * @return object
     */
    public static function getCurrentCMSCategory()
    {
        return self::$category;
    }

    public function viewAccess($disable = false)
    {
        $result = parent::viewAccess($disable);
        $this->admin_cms_categories->tabAccess = $this->tabAccess;
        $this->admin_cms->tabAccess = $this->tabAccess;
        return $result;
    }

    public function initContent()
    {
        $this->initTabModuleList();
        $this->renderPageHeaderToolbar();
        
        $this->admin_cms_categories->token = $this->token;
        $this->admin_cms->token = $this->token;

        if ($this->display == 'edit_category')
            $this->content .= $this->admin_cms_categories->renderForm();
        elseif ($this->display == 'edit_page')
            $this->content .= $this->admin_cms->renderForm();
        elseif ($this->display == 'view_page')
            $fixme = 'fixme';// @FIXME
        else
        {
            $id_cms_category = (int)Tools::getValue('id_cms_category');
            if (!$id_cms_category)
                $id_cms_category = 1;

            // CMS categories breadcrumb
            $cms_tabs = array('cms_category', 'cms');
            // Cleaning links
            $cat_bar_index = self::$currentIndex;
            foreach ($cms_tabs as $tab)
                if (Tools::getValue($tab.'Orderby') && Tools::getValue($tab.'Orderway'))
                    $cat_bar_index = preg_replace('/&'.$tab.'Orderby=([a-z _]*)&'.$tab.'Orderway=([a-z]*)/i', '', self::$currentIndex);
            $this->context->smarty->assign(array(
                'cms_breadcrumb' => getPath($cat_bar_index, $id_cms_category, '', '', 'cms'),
                'page_header_toolbar_btn' => $this->page_header_toolbar_btn,
                'page_header_toolbar_title' => $this->toolbar_title,
            ));
            
            $this->content .= $this->admin_cms_categories->renderList();
            $this->admin_cms->id_cms_category = $id_cms_category;
            $this->content .= $this->admin_cms->renderList();
            
        }

        $this->context->smarty->assign(array(
            'content' => $this->content
        ));
    }

    public function renderPageHeaderToolbar()
    {
        $id_cms_category = (int)Tools::getValue('id_cms_category');
        $id_cms_page = Tools::getValue('id_cms');

        if (!$id_cms_category)
            $id_cms_category = 1;

        $cms_category = new CMSCategory($id_cms_category);

        if ($this->display == 'edit_category')
        {
            if (Tools::getValue('addcms_category') !== false)
                $this->toolbar_title[] = $this->l('Add new');
            else
                $this->toolbar_title[] = sprintf($this->l('Edit: %s'), $cms_category->name[$this->context->employee->id_lang]);
        }
        elseif ($this->display == 'edit_page')
        {
            $this->toolbar_title[] = $cms_category->name[$this->context->employee->id_lang];

            if (Tools::getValue('addcms') !== false)
                $this->toolbar_title[] = $this->l('Add new');
            elseif ($id_cms_page)
            {
                $cms_page = new CMS($id_cms_page);
                $this->toolbar_title[] = sprintf($this->l('Edit: %s'), $cms_page->meta_title[$this->context->employee->id_lang]);
            }
        }
        else
            $this->toolbar_title[] = $this->l('CMS');

        if ($this->display == 'list')
        {
            $this->page_header_toolbar_btn['new_cms_category'] = array(
                'href' => self::$currentIndex.'&addcms_category&token='.$this->token,
                'desc' => $this->l('Add new CMS category', null, null, false),
                'icon' => 'process-icon-new'
            );
            $this->page_header_toolbar_btn['new_cms_page'] = array(
                'href' => self::$currentIndex.'&addcms&id_cms_category='.(int)$id_cms_category.'&token='.$this->token,
                'desc' => $this->l('Add new CMS page', null, null, false),
                'icon' => 'process-icon-new'
            );
        }

        $this->page_header_toolbar_title = implode(' '.Configuration::get('PS_NAVIGATION_PIPE').' ', $this->toolbar_title);

        if (is_array($this->page_header_toolbar_btn)
            && $this->page_header_toolbar_btn instanceof Traversable
            || trim($this->page_header_toolbar_title) != '')
            $this->show_page_header_toolbar = true;

        $template = $this->context->smarty->createTemplate(
            $this->context->smarty->getTemplateDir(0).DIRECTORY_SEPARATOR
            .'page_header_toolbar.tpl', $this->context->smarty);

        $this->context->smarty->assign(array(
            'show_page_header_toolbar' => $this->show_page_header_toolbar,
            'title' => $this->page_header_toolbar_title,
            'toolbar_btn' => $this->page_header_toolbar_btn,
            'page_header_toolbar_btn' => $this->page_header_toolbar_btn,
            'page_header_toolbar_title' => $this->toolbar_title,
        ));
    }

    public function postProcess()
    {
        /*if (Tools::isSubmit('submitDelcms')
            || Tools::isSubmit('previewSubmitAddcmsAndPreview')
            || Tools::isSubmit('submitAddcms')
            || Tools::isSubmit('submitBulkdeletecms')
            || Tools::isSubmit('deletecms')
            || Tools::isSubmit('viewcms')
            || (Tools::isSubmit('statuscms') && Tools::isSubmit('id_cms'))
            || (Tools::isSubmit('way') && Tools::isSubmit('id_cms')) && (Tools::isSubmit('position'))
            || Tools::isSubmit('submitFiltercms')
            || $this->context->cookie->{'submitFiltercms'} !== false
            || Tools::getValue('cmsOrderby')
            || Tools::getValue('cmsOrderway'))*/
            $this->admin_cms->postProcess();
        /*elseif (Tools::isSubmit('submitDelcms_category')
            || Tools::isSubmit('submitAddcms_categoryAndBackToParent')
            || Tools::isSubmit('submitBulkdeletecms_category')
            || Tools::isSubmit('submitAddcms_category')
            || Tools::isSubmit('deletecms_category')
            || (Tools::isSubmit('statuscms_category') && Tools::isSubmit('id_cms_category'))
            || (Tools::isSubmit('position') && Tools::isSubmit('id_cms_category_to_move'))
            || Tools::isSubmit('submitFiltercms_category')
            || $this->context->cookie->{'submitFiltercms_category'} !== false
            || Tools::getValue('cms_categoryOrderby')
            || Tools::getValue('cms_categoryOrderway'))*/
                $this->admin_cms_categories->postProcess();
      //else
            parent::postProcess();

        if (((Tools::isSubmit('submitAddcms_category') || Tools::isSubmit('submitAddcms_categoryAndStay')) && count($this->admin_cms_categories->errors))
            || Tools::isSubmit('updatecms_category')
            || Tools::isSubmit('addcms_category'))
            $this->display = 'edit_category';
        elseif (((Tools::isSubmit('submitAddcms') || Tools::isSubmit('submitAddcmsAndStay')) && count($this->admin_cms->errors))
            || Tools::isSubmit('updatecms')
            || Tools::isSubmit('addcms'))
            $this->display = 'edit_page';
        else
        {
            $this->display = 'list';
            $this->id_cms_category = (int)Tools::getValue('id_cms_category');
        }

        if (isset($this->admin_cms->errors))
            $this->errors = array_merge($this->errors, $this->admin_cms->errors);

        if (isset($this->admin_cms_categories->errors))
            $this->errors = array_merge($this->errors, $this->admin_cms_categories->errors);
    }

    public function setMedia()
    {
        parent::setMedia();
        $this->addJqueryUi('ui.widget');
        $this->addJqueryPlugin('tagify');
    }

    public function ajaxProcessUpdateCmsPositions()
    {
        if ($this->tabAccess['edit'] === '1')
        {
            $id_cms = (int)Tools::getValue('id_cms');
            $id_category = (int)Tools::getValue('id_cms_category');
            $way = (int)Tools::getValue('way');
            $positions = Tools::getValue('cms');
            if (is_array($positions))
                foreach ($positions as $key => $value)
                {
                    $pos = explode('_', $value);
                    if ((isset($pos[1]) && isset($pos[2])) && ($pos[1] == $id_category && $pos[2] == $id_cms))
                    {
                        $position = $key;
                        break;
                    }
                }
            $cms = new CMS($id_cms);
            if (Validate::isLoadedObject($cms))
            {
                if (isset($position) && $cms->updatePosition($way, $position))
                    die(true);
                else
                    die('{"hasError" : true, "errors" : "Can not update cms position"}');
            }
            else
                die('{"hasError" : true, "errors" : "This cms can not be loaded"}');
        }
    }

    public function ajaxProcessUpdateCmsCategoriesPositions()
    {
        if ($this->tabAccess['edit'] === '1')
        {
            $id_cms_category_to_move = (int)Tools::getValue('id_cms_category_to_move');
            $id_cms_category_parent = (int)Tools::getValue('id_cms_category_parent');
            $way = (int)Tools::getValue('way');
            $positions = Tools::getValue('cms_category');
            if (is_array($positions))
                foreach ($positions as $key => $value)
                {
                    $pos = explode('_', $value);
                    if ((isset($pos[1]) && isset($pos[2])) && ($pos[1] == $id_cms_category_parent && $pos[2] == $id_cms_category_to_move))
                    {
                        $position = $key;
                        break;
                    }
                }
            $cms_category = new CMSCategory($id_cms_category_to_move);
            if (Validate::isLoadedObject($cms_category))
            {
                if (isset($position) && $cms_category->updatePosition($way, $position))
                    die(true);
                else
                    die('{"hasError" : true, "errors" : "Can not update cms categories position"}');
            }
            else
                die('{"hasError" : true, "errors" : "This cms category can not be loaded"}');
        }
    }

    public function ajaxProcessPublishCMS()
    {
        if ($this->tabAccess['edit'] === '1')
        {
            if ($id_cms = (int)Tools::getValue('id_cms'))
            {
                $bo_cms_url = _PS_BASE_URL_.__PS_BASE_URI__.basename(_PS_ADMIN_DIR_).'/index.php?tab=AdminCmsContent&id_cms='.(int)$id_cms.'&updatecms&token='.$this->token;

                if (Tools::getValue('redirect'))
                    die($bo_cms_url);

                $cms = new CMS((int)(Tools::getValue('id_cms')));
                if (!Validate::isLoadedObject($cms))
                    die('error: invalid id');

                $cms->active = 1;
                if ($cms->save())
                    die($bo_cms_url);
                else
                    die('error: saving');
            }
            else
                die ('error: parameters');
        }
    }

}
 

Thank you again

 

Tina

www.climaticmoments.com

Link to comment
Share on other sites

I guess that wasn't my only issue

 

I thought when I uninstalled and reinstalled the top horizontal menu it fixed the issue with all the links and weird empty transparent box in the middle of it, but it didn't.

 

When I add the categories and a home link, it gives a 404 error for home. So if I was on a category the home would come up as www.climaticmoments.com/herbals/climaticmoments.com.

 

I am not sure if the two are related issues the cms and the top horizontal menu.

 

Is there a way to rerun just these two issues from the update 1.6.0.13?

 

Thank you again for any help anyone can offer.

 

Tina

www.climaticmoments.com

Link to comment
Share on other sites

I really hope someone can help me soon because my website does not have any cms pages for customer service reasons or in the top menu.

 

I compared my current data bases to my 1.6..0.9 and 1.6.0.11 to my current 1.6.0.14 and nothing really stood out.

 

All the Cms pages are showing in my current database when I goto phpmyadmin, but when I open them in prestashop they are blank and I can not edit, add, or change them.

 

Everytime I add links to the top menu it links completey wrong.

 

Please please please can someone help me.

 

Thank you again

 

Tina

www.climaticmoments.com

Link to comment
Share on other sites

Hi again,

 

I can't express how much I appreciate your help.

 

I added an id_shop column with int(12) to cms_category_lang like you asked with this

 

--
-- Table structure for table `ps_cms_category_lang`
--

DROP TABLE IF EXISTS `ps_cms_category_lang`;
CREATE TABLE IF NOT EXISTS `ps_cms_category_lang` (
  `id_cms_category` int(10) unsigned NOT NULL,
  `id_shop` int(12) unsigned NOT NULL DEFAULT '1',
  `id_lang` int(10) unsigned NOT NULL,
  `name` varchar(128) NOT NULL,
  `description` text,
  `link_rewrite` varchar(128) NOT NULL,
  `meta_title` varchar(128) DEFAULT NULL,
  `meta_keywords` varchar(255) DEFAULT NULL,
  `meta_description` varchar(255) DEFAULT NULL,
  PRIMARY KEY (`id_cms_category`,`id_lang`),
  KEY `category_name` (`name`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

--
-- Dumping data for table `ps_cms_category_lang`
--

INSERT INTO `ps_cms_category_lang` (`id_cms_category`, `id_lang`, `name`, `description`, `link_rewrite`, `meta_title`, `meta_keywords`, `meta_description`) VALUES
(1, 1, 'Home', NULL, 'home', NULL, NULL, NULL),
(3, 1, 'Customer Service', 'Resources links to help you find important information faster.', 'customer-service', 'Customer Service', NULL, 'Customer Service at Climatic Moments'),
(5, 1, 'How to Sex Toy Guides', 'Bondage and Sex Toy Product Guides\r\n\r\nFinding the right adult products for yourself or partner can be a daunting task. Even as you browse through our site, you''ll find over 3,000 BDSM products and sex toys. Don''t worry our product guides are designed to help you learn more about these products and how they can be used to improve your sexual pleasure. Enjoy reading through our sex toy and bondage guides and we hope you''ll learn more about the many different ways you can bring your sex life to a whole new satisfying level.  \r\n', 'how-to-sex-toy-guides', 'How to Sex Toy Guides | Climatic Moments | How to BDSM Guides', 'how to sex toy guides,how to bdsm guides,what sex toys should I buy,how to buy bondage gear', ' Finding the right sex toys and bdsm products for yourself or partner can be a daunting task. Browse our Free how to sex toy guides at Climatic Moments to help you find the perfect sex toys to enhance your sex life.'),
(6, 1, 'Sexual Education', 'Discovering what can heighten, enhance, and renew your sexual needs and your relationships can be overwhelming and expensive without the right resources. This Sexual Education section includes information and links to help you explore, educate, and learn about these topics.', 'sexual-education', 'Sexual Education | Climatic Moments | How to Sex Guides', 'free sexual guides, how to sex guides', 'Discover Free Sexual Guides and Help at Climatic Moments.'),
(8, 1, 'More Info', NULL, 'more-info', 'More Info | Climatic Moments', NULL, NULL);

/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;

 

It shows the new column now id_shop now.

 

I then deleted the smarty compile cache, the template cache, browser cache, temp files etc.

I deleted the .htaccess and regenerated one.

 

I clicked on cms with error reporting on and this is what I am getting now

 

[PrestaShopDatabaseException]

Unknown column 'id_shop' in 'where clause'

SELECT * FROM `ps_cms_lang`
                                WHERE `id_cms` = 16 AND `id_shop` = 1


at line 646 in file classes/db/Db.php

641.             WebserviceRequest::getInstance()->setError(500, '

 '.$this->getMsgError().'. From '.(isset($dbg[3]['class']) ? $dbg[3]['class'] : '').'->'.$dbg[3]['function'].'() Query was : '.$sql, 97);
642.         }
643.         elseif (_PS_DEBUG_SQL_ && $errno && !defined('PS_INSTALLATION_IN_PROGRESS'))
644.         {
645.             if ($sql)
646.                 throw new PrestaShopDatabaseException($this->getMsgError().'<br /><br /><pre>'.$sql.'</pre>');
647.             throw new PrestaShopDatabaseException($this->getMsgError());
648.         }
649.     }
650.
651.     /**

    DbCore->displayError - [line 340 - classes/db/Db.php] - [1 Arguments]

    335.             if ($this->connect())
    336.                 $this->result = $this->_query($sql);
    337.         }
    338.
    339.         if (_PS_DEBUG_SQL_)
    340.             $this->displayError($sql);
    341.         return $this->result;
    342.     }
    343.
    344.     /**
    345.      * Execute an INSERT query

    DbCore->query - [line 516 - classes/db/Db.php] - [1 Arguments]

    511.         {
    512.             $this->last_cached = true;
    513.             return $result;
    514.         }
    515.
    516.         $this->result = $this->query($sql);
    517.
    518.         if (!$this->result)
    519.             $result = false;
    520.         else
    521.         {

    DbCore->executeS - [line 240 - classes/ObjectModel.php] - [1 Arguments]

    235.                     if (!$id_lang && isset($this->def['multilang']) && $this->def['multilang'])
    236.                     {
    237.                         $sql = 'SELECT * FROM `'.pSQL(_DB_PREFIX_.$this->def['table']).'_lang`
    238.                                 WHERE `'.bqSQL($this->def['primary']).'` = '.(int)$id
    239.                                 .(($this->id_shop && $this->isLangMultishop()) ? ' AND `id_shop` = '.$this->id_shop : '');
    240.                         if ($object_datas_lang = ObjectModel::$db->executeS($sql))
    241.                             foreach ($object_datas_lang as $row)
    242.                                 foreach ($row as $key => $value)
    243.                                 {
    244.                                     if ($key != $this->def['primary'] && array_key_exists($key, $this))
    245.                                     {

    ObjectModelCore->__construct - [line 151 - controllers/admin/AdminCmsContentController.php] - [1 Arguments]

    146.
    147.             if (Tools::getValue('addcms') !== false)
    148.                 $this->toolbar_title[] = $this->l('Add new');
    149.             elseif ($id_cms_page)
    150.             {
    151.                 $cms_page = new CMS($id_cms_page);
    152.                 $this->toolbar_title[] = sprintf($this->l('Edit: %s'), $cms_page->meta_title[$this->context->employee->id_lang]);
    153.             }
    154.         }
    155.         else
    156.             $this->toolbar_title[] = $this->l('CMS');

    AdminCmsContentControllerCore->renderPageHeaderToolbar - [line 85 - controllers/admin/AdminCmsContentController.php]

    80.     }
    81.
    82.     public function initContent()
    83.     {
    84.         $this->initTabModuleList();
    85.         $this->renderPageHeaderToolbar();
    86.         
    87.         $this->admin_cms_categories->token = $this->token;
    88.         $this->admin_cms->token = $this->token;
    89.
    90.         if ($this->display == 'edit_category')

    AdminCmsContentControllerCore->initContent - [line 180 - classes/controller/Controller.php]

    175.
    176.             if (!$this->content_only && ($this->display_header || (isset($this->className) && $this->className)))
    177.                 $this->initHeader();
    178.
    179.             if ($this->viewAccess())
    180.                 $this->initContent();
    181.             else
    182.                 $this->errors[] = Tools::displayError('Access denied.');
    183.
    184.             if (!$this->content_only && ($this->display_footer || (isset($this->className) && $this->className)))
    185.                 $this->initFooter();

    ControllerCore->run - [line 373 - classes/Dispatcher.php]

    368.             // Execute hook dispatcher
    369.             if (isset($params_hook_action_dispatcher))
    370.                 Hook::exec('actionDispatcher', $params_hook_action_dispatcher);
    371.
    372.             // Running controller
    373.             $controller->run();
    374.         }
    375.         catch (PrestaShopException $e)
    376.         {
    377.             $e->displayMessage();
    378.         }

    DispatcherCore->dispatch - [line 54 - admin/index.php]

    49.     $_POST['controller'] = strtolower($_POST['tab']);
    50. if (!isset($_REQUEST['controller']) && isset($_REQUEST['tab']))
    51.     $_REQUEST['controller'] = strtolower($_REQUEST['tab']);
    52.
    53. // Prepare and trigger admin dispatcher
    54. Dispatcher::getInstance()->dispatch();
 

I am really sorry to be such a pain in the behind.

 

Thank you again.

 

Tina

www.climaticmoments.com

Link to comment
Share on other sites

  • 2 months later...

Hello,

I have exactly the same problem.

 I add id_shop column as int(12) to cms_category_lang and cms_lang but now I have communique
Duplicate entry '1-1' for key 'PRIMARY'
 
INSERT INTO `ps_cms_lang` (`id_cms`, `meta_description`, `meta_keywords`, `meta_title`, `link_rewrite`, `content`, `id_lang`, `id_shop`) VALUES ('1', '', '', 'dostawa', 'dostawa', '', '1', '1')
 
What should i fix?
Link to comment
Share on other sites

With other cms texts I have similar problem.

For example,with Terms and conditions of use i have communique:

Duplicate entry '3-1' for key 'PRIMARY'

INSERT INTO `ps_cms_lang` (`id_cms`, `meta_description`, `meta_keywords`, `meta_title`, `link_rewrite`, `content`, `id_lang`, `id_shop`) VALUES ('3', '', '', 'warunki', 'warunki', '', '1', '1')

Link to comment
Share on other sites

  • 2 months later...

No pain really :)

At this point, add the column to cms_lang as well, it should fix it

 

I apologize for my English is very basic.
 
I'm new "prestashop" and these types of errors drive me crazy, but thank you for this solution!
 
I would love to thank, from Argentina.
Link to comment
Share on other sites

  • 2 months later...
  • 6 months later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...