Post by sidclel » Tue Jul 01, 2025 10:14 pm

Guys, how or what code to use to create an ocmod. to save mandatory titles and descriptions only in the main language, the others remain blank until I edit the product and put the text in it. In front, the user when selecting another language of the main product that does not have the titles and description is directed to Home if

https://www.saleples.com/


New member

Posts

Joined
Sat Apr 14, 2012 9:19 am


Post by khnaz35 » Wed Jul 02, 2025 2:47 am

Opencart version? Theme being used?
Most likely you need to work with

admin/controller/catalog/product.php (filter non-default languages)
catalog/controller/product/product.php (redirect when missing data)

Got an urgent question that’s keeping you up at night? There might just be a magical inbox ready to help: khnaz35@gmail.com
Enjoy nature ;) :) :-*


User avatar
Active Member
Online

Posts

Joined
Mon Aug 27, 2018 11:30 pm
Location - Malaysia

Post by sidclel » Thu Jul 03, 2025 10:21 pm

opencart 3.0.3.9 The right question is how to publish and save only 1 language without language priority the others are blank until I write in it

https://www.saleples.com/


New member

Posts

Joined
Sat Apr 14, 2012 9:19 am


Post by khnaz35 » Thu Jul 03, 2025 10:37 pm


Got an urgent question that’s keeping you up at night? There might just be a magical inbox ready to help: khnaz35@gmail.com
Enjoy nature ;) :) :-*


User avatar
Active Member
Online

Posts

Joined
Mon Aug 27, 2018 11:30 pm
Location - Malaysia

Post by OSWorX » Fri Jul 04, 2025 2:05 am

sidclel wrote:
Tue Jul 01, 2025 10:14 pm
Guys, how or what code to use to create an ocmod. to save mandatory titles and descriptions only in the main language, the others remain blank until I edit the product and put the text in it. In front, the user when selecting another language of the main product that does not have the titles and description is directed to Home if
Sorry, but what you're writing is completely nonsens!
When you provide several languages (as store owner) I ( as visitor) exprect that everything is in all provided languages.
Clicking now on another language and seeing blank fields (or no titles and no descriptions) - or much worser! - redirects me automatically to another (home) page, leads me to leave that store as quickly as I can!

I have made an extension to hide all those fields if a language is not enabled: https://www.opencart.com/index.php?rout ... n_id=27975
No extra work has to be done if a language is not enabled - and if enabled again, no further action is required.
This let's you switch between - if you need, want, etc ...

Full Stack Web Developer :: Dedicated OpenCart Development & Support DACH Region
Contact for Custom Work / Fast Support.


User avatar
Administrator

Posts

Joined
Mon Jan 11, 2010 10:52 pm
Location - Austria
Who is online

Users browsing this forum: Bing [Bot] and 104 guests