niiko86 Posted May 17, 2016 Share Posted May 17, 2016 Hello last week I changed the domain name of my shop in my store and now i can't edit my product or add new. This is the error i get.Notice on line 1481 in file /var/www/vhosts/clima-holder.gr/httpdocs/clima-holder/classes/controller/AdminController.php[8] Undefined offset: 0Notice on line 1490 in file /var/www/vhosts/clima-holder.gr/httpdocs/clima-holder/classes/controller/AdminController.php[8] Array to string conversionThank you Link to comment Share on other sites More sharing options...
NemoPS Posted May 18, 2016 Share Posted May 18, 2016 PrestaShop version? WHat do you have on those lines in the file? Link to comment Share on other sites More sharing options...
niiko86 Posted May 18, 2016 Author Share Posted May 18, 2016 Prestashop Version 1.6.1.4 line 1481 $this->toolbar_title[] = is_array($obj->{$this->identifier_name}) ? $obj->{$this->identifier_name}[$this->context->employee->id_lang] : $obj->{$this->identifier_name}; line 1490 $this->toolbar_title[] = sprintf($this->l('Edit: %s'), (is_array($obj->{$this->identifier_name}) && isset($obj->{$this->identifier_name}[$this->context->employee->id_lang])) ? $obj->{$this->identifier_name}[$this->context->employee->id_lang] : $obj->{$this->identifier_name}); Link to comment Share on other sites More sharing options...
NemoPS Posted May 20, 2016 Share Posted May 20, 2016 Can you tryd($this->context->employee->id_lang);?See if it reads 0 or a number Link to comment Share on other sites More sharing options...
niiko86 Posted May 20, 2016 Author Share Posted May 20, 2016 Sorry i dont understand, did i have to replace it like $this->toolbar_title[] = is_array($obj->{$this->identifier_name}) ? $obj->d($this->context->employee->id_lang);? : $obj->{$this->identifier_name}; Link to comment Share on other sites More sharing options...
NemoPS Posted May 21, 2016 Share Posted May 21, 2016 No, before that, just try dumping the value to see if it's the 0 that kills the page Link to comment Share on other sites More sharing options...
niiko86 Posted May 22, 2016 Author Share Posted May 22, 2016 String(1)"0" I try it with var_dump Link to comment Share on other sites More sharing options...
NemoPS Posted May 23, 2016 Share Posted May 23, 2016 Really odd, the language is 0 for the current employee. Did you erase any language recently? How many does your store have?Also, I would try reaching Administration -> Employees, click on your user and see what the language is. Eventually, save the page again and retry with the product Link to comment Share on other sites More sharing options...
niiko86 Posted May 23, 2016 Author Share Posted May 23, 2016 In the beginning i start with 3 languages german english greek. But now i use only greek I change in Administration -> Employees to greek and it works again String(1)"3" Thank you Link to comment Share on other sites More sharing options...
nicmeric Posted June 23, 2016 Share Posted June 23, 2016 You Save my day! Thank's!!! Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now