I upgrade version opencart to 3.0.3.8
Today i see some problem
i have article
https://www.agrogradina.bg/semena/semen ... ok-agrosel - work url
https://www.agrogradina.bg/artishok-agrosel - work url
i use modul to see article in category
but url:
https://www.agrogradina.bg/semena/semen ... ok-agrosel
https://www.agrogradina.bg/semena/artishok-agrosel
not work
i see in category and subcategory article but when i click i see massege not fount
Product not found!
idea?
Today i see some problem
i have article
https://www.agrogradina.bg/semena/semen ... ok-agrosel - work url
https://www.agrogradina.bg/artishok-agrosel - work url
i use modul to see article in category
but url:
https://www.agrogradina.bg/semena/semen ... ok-agrosel
https://www.agrogradina.bg/semena/artishok-agrosel
not work
i see in category and subcategory article but when i click i see massege not fount
Product not found!
idea?
If you are using an extension to make you products appear in parent categories, it would probably need to be updated to work with 3.0.3.8, due to the changes below.
https://github.com/opencart/opencart/pull/9478
https://github.com/opencart/opencart/pull/9478
From what version and how did you do it?
UK OpenCart Hosting | OpenCart Audits | OpenCart Support - please email info@antropy.co.uk
3.0.3.2 to 3.0.3.8
update standart
Upload files to your server
Run automatic installer
now i see new problem. i can not make new product... i have error
Fatal error: Uncaught Exception: Error: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'UNION SELECT DISTINCT image FROM ocim_product WHERE product_id=' at line 2<br />Error No: 1064<br />SELECT DISTINCT image FROM ocim_product_image WHERE product_id= UNION SELECT DISTINCT image FROM ocim_product WHERE product_id= in /home/gameuthv/public_html/seedsbg.com/system/library/db/mysqli.php:48 Stack trace: #0 /home/gameuthv/public_html/seedsbg.com/system/library/db.php(45): DB\MySQLi->query('SELECT DISTINCT...') #1 /home/gameuthv/public_html/seedsbg.com/system/ocmodify/classes/override/database.php(18): DB->query('SELECT DISTINCT...', Array) #2 /home/gameuthv/public_html/seedsbg.com/system/ocmodify/classes/engine/bridge.php(47): OCMDatabase->query('SELECT DISTINCT...') #3 /home/gameuthv/public_html/seedsbg.com/system/storage/modification/admin/model/catalog/product.php(463): OCMBridge->__call('query', Array) #4 /home/gameuthv/public_ht in /home/gameuthv/public_html/seedsbg.com/system/library/db/mysqli.php on line 48
update standart
Upload files to your server
Run automatic installer
now i see new problem. i can not make new product... i have error
Fatal error: Uncaught Exception: Error: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'UNION SELECT DISTINCT image FROM ocim_product WHERE product_id=' at line 2<br />Error No: 1064<br />SELECT DISTINCT image FROM ocim_product_image WHERE product_id= UNION SELECT DISTINCT image FROM ocim_product WHERE product_id= in /home/gameuthv/public_html/seedsbg.com/system/library/db/mysqli.php:48 Stack trace: #0 /home/gameuthv/public_html/seedsbg.com/system/library/db.php(45): DB\MySQLi->query('SELECT DISTINCT...') #1 /home/gameuthv/public_html/seedsbg.com/system/ocmodify/classes/override/database.php(18): DB->query('SELECT DISTINCT...', Array) #2 /home/gameuthv/public_html/seedsbg.com/system/ocmodify/classes/engine/bridge.php(47): OCMDatabase->query('SELECT DISTINCT...') #3 /home/gameuthv/public_html/seedsbg.com/system/storage/modification/admin/model/catalog/product.php(463): OCMBridge->__call('query', Array) #4 /home/gameuthv/public_ht in /home/gameuthv/public_html/seedsbg.com/system/library/db/mysqli.php on line 48
Looks to be an issue with one of your extensions. Disable them one by one until you find which one.
I understand this is an old thread, but I wanted to actually share a solution since this thread shows up on google and I want to help others that come across this.
Basically if you use any of those classic 2.0-3.0 OpenCart VQMods that shows products from child categories onto the parent categories.
Aka the manual mod where you add underneath in \catalog\controller\product\category.php that lots of people mention here and stackoverflow.
You'll find that the child products show in parent categories now, but when clicking on them you get "Product not found!"
That's due to this commit: https://github.com/opencart/opencart/co ... 77a7614ed7
It was a bugfix so shoppers can't mess with the SEO url for categories. So someone cant change coolshop.net/furniture/oakchair12 to some gibberish like coolshop.net/irgn6dodrg iuopfdbi/oakchair12.
Although really, I find this fix not that important honestly, because it only needs to check the end bit anyway to get the product, plus this commit tends to break a few other old VQMods from my testing.
So the workaround I found (for at least OpenCart 3.0.3.8 ) is to just revert the behavior, additionally this also fixed the 500 server error I was having on another VQmod that generated thumbnails for embeds on discord/facebook/twitter etc that had trouble on some of the urls.
To apply the workaround, open:
\catalog\controller\product\product.php
find these lines
And either delete it or comment it out. I commented this on mine using /* and */:
Hope this helps somebody in the future! 
Basically if you use any of those classic 2.0-3.0 OpenCart VQMods that shows products from child categories onto the parent categories.
Aka the manual mod where you add
Code: Select all
'filter_sub_category' => true,
Code: Select all
$filter_data = array(
'filter_category_id' => $category_id,
You'll find that the child products show in parent categories now, but when clicking on them you get "Product not found!"
That's due to this commit: https://github.com/opencart/opencart/co ... 77a7614ed7
It was a bugfix so shoppers can't mess with the SEO url for categories. So someone cant change coolshop.net/furniture/oakchair12 to some gibberish like coolshop.net/irgn6dodrg iuopfdbi/oakchair12.
Although really, I find this fix not that important honestly, because it only needs to check the end bit anyway to get the product, plus this commit tends to break a few other old VQMods from my testing.
So the workaround I found (for at least OpenCart 3.0.3.8 ) is to just revert the behavior, additionally this also fixed the 500 server error I was having on another VQmod that generated thumbnails for embeds on discord/facebook/twitter etc that had trouble on some of the urls.
To apply the workaround, open:
\catalog\controller\product\product.php
find these lines
Code: Select all
//check product page open from cateory page
if (isset($this->request->get['path'])) {
$parts = explode('_', (string)$this->request->get['path']);
if(empty($this->model_catalog_product->checkProductCategory($product_id, $parts))) {
$product_info = array();
}
}
Code: Select all
//check product page open from cateory page
/* DISABLE!!!, BREAKS SHOWING SUBCATEGORIES IN PARENTS - 11/11/22
if (isset($this->request->get['path'])) {
$parts = explode('_', (string)$this->request->get['path']);
if(empty($this->model_catalog_product->checkProductCategory($product_id, $parts))) {
$product_info = array();
}
}*/

Very well done.
As you aren't the original author, I'll add [SOLVED] to the start of the post title.
UK OpenCart Hosting | OpenCart Audits | OpenCart Support - please email info@antropy.co.uk
Who is online
Users browsing this forum: No registered users and 18 guests