Post by paketonlinestore » Thu Jan 30, 2014 11:07 am

Hello, I have been dealing with Undefined index Errors in product.php recently, I suspect it happens everytime the user is creating/input a new product on the dashboard. How to fix these errors cause it makes the server resource overload, my site resource usage peaked at 91% sometimes 100% on the cpanel. Please help me how to fix this, thanks before. Any advices is greatly appreciated

PHP Notice: Undefined index: model in /home/xxx/public_html/admin/controller/catalog/product.php on line 651
PHP Notice: Undefined index: sku in /home/xxx/public_html/admin/controller/catalog/product.php on line 659
PHP Notice: Undefined index: location in /home/xxx/public_html/admin/controller/catalog/product.php on line 667
PHP Notice: Undefined index: keyword in /home/xxx/public_html/admin/controller/catalog/product.php on line 687
PHP Notice: Undefined index: image in /home/xxx/public_html/admin/controller/catalog/product.php on line 703
PHP Notice: Undefined index: image in /home/xxx/public_html/admin/controller/catalog/product.php on line 710
PHP Notice: Undefined index: manufacturer_id in /home/xxx/public_html/admin/controller/catalog/product.php on line 723
PHP Notice: Undefined index: shipping in /home/xxx/public_html/admin/controller/catalog/product.php on line 731
PHP Notice: Undefined index: date_available in /home/xxx/public_html/admin/controller/catalog/product.php on line 739
PHP Notice: Undefined index: quantity in /home/xxx/public_html/admin/controller/catalog/product.php on line 747
PHP Notice: Undefined index: minimum in /home/xxx/public_html/admin/controller/catalog/product.php on line 755
PHP Notice: Undefined index: subtract in /home/xxx/public_html/admin/controller/catalog/product.php on line 763
PHP Notice: Undefined index: sort_order in /home/xxx/public_html/admin/controller/catalog/product.php on line 771
PHP Notice: Undefined index: stock_status_id in /home/xxx/public_html/admin/controller/catalog/product.php on line 783
PHP Notice: Undefined index: price in /home/xxx/public_html/admin/controller/catalog/product.php on line 791
PHP Notice: Undefined index: cost in /home/xxx/public_html/admin/controller/catalog/product.php on line 799
PHP Notice: Undefined index: status in /home/xxx/public_html/admin/controller/catalog/product.php on line 807
PHP Notice: Undefined index: tax_class_id in /home/xxx/public_html/admin/controller/catalog/product.php on line 819
PHP Notice: Undefined index: weight in /home/xxx/public_html/admin/controller/catalog/product.php on line 827
PHP Notice: Undefined index: weight_class_id in /home/xxx/public_html/admin/controller/catalog/product.php on line 841
PHP Notice: Undefined index: length in /home/xxx/public_html/admin/controller/catalog/product.php on line 851
PHP Notice: Undefined index: width in /home/xxx/public_html/admin/controller/catalog/product.php on line 859
PHP Notice: Undefined index: height in /home/xxx/public_html/admin/controller/catalog/product.php on line 867
PHP Notice: Undefined index: length_class_id in /home/xxx/public_html/admin/controller/catalog/product.php on line 881


Posts

Joined
Fri Jun 28, 2013 11:37 am

Post by nvedia » Fri Jan 31, 2014 9:13 am

It looks like all the values above are blank and hence the error
How are you inserting the product? csv export / import?

Donate here to show support if you think I have helped you today!

Opencart Documentation


User avatar
Active Member

Posts

Joined
Sun May 22, 2011 12:54 pm

Post by paketonlinestore » Mon Feb 03, 2014 10:59 am

nvedia wrote:It looks like all the values above are blank and hence the error
How are you inserting the product? csv export / import?
Hello thanks for replying, my client doesn't have any access to cpanel hence i dont think he is doing the manual csv import through database. I think he just inserting the product using the manual opencart admin dashboard.

I am using opencart 1.4.9 here is the model file: http://pastebin.com/RNJP80aF and here is the controller file: http://pastebin.com/mr9AUPjR for reference


Posts

Joined
Fri Jun 28, 2013 11:37 am

Post by butte » Mon Feb 03, 2014 11:36 am

Theme? If you are not using the default/ theme, then ask the theme author.

Blank values will ordinarily not throw undefined index. Values go into a box or database field/record (column/row) intersect cell. Indices are defined in code that fetches or otherwise fiddles with any values that are put into the boxes.

Guru Member

Posts

Joined
Wed Mar 20, 2013 6:58 am

Post by gailnmalc » Sat May 27, 2017 2:57 am

Hi, I had a feed from my suppliers inserted into my site via my hosts, ( i am on 1.5.6) my categories update fine but the products give me a great list of errors saying the same thing. Notice: Undefined index: keyword in /home/shop/public_html/admin/model/catalog/product.php on line 113. On line 113 it says if ($data['keyword']) { I am not computer wizz, but is anything missing from the coding or anything? Any help would be massively appreciated.

User avatar
Newbie

Posts

Joined
Sun Aug 16, 2015 1:56 am

Post by svayamalhotra » Thu Jun 01, 2017 2:26 pm

This is because of OCMOD modification files, You have to edit or recheck your model folder's product.php file in system > modification > catalog > model > product.php

You can email us at webmaster@alienskart.com / https://alienskart.com

Newbie

Posts

Joined
Thu Jun 01, 2017 2:16 pm
Who is online

Users browsing this forum: No registered users and 53 guests