Hi all,
Firstly, I am loving Open Cart. Nice to get hold of a platform so neatly built.
OK, So this is my problem.
I am trying to create an alternative layout for certain products. For instance, some products will use the standard product layout file (product.tpl) and others will use an alternative layout.
I have tried creating a new layout called alternative_product.tpl and copied it from the product.tpl. I have added athe new layout in the admin area (System > Design > Layouts) have then assigned it to a product to test it but it seems to use the default layout. Of course, I have made some modifications to check it works.
Do I need to create a new controller to manage this? How does it work?
Any help would be much appreciated.
Cheers
Firstly, I am loving Open Cart. Nice to get hold of a platform so neatly built.
OK, So this is my problem.
I am trying to create an alternative layout for certain products. For instance, some products will use the standard product layout file (product.tpl) and others will use an alternative layout.
I have tried creating a new layout called alternative_product.tpl and copied it from the product.tpl. I have added athe new layout in the admin area (System > Design > Layouts) have then assigned it to a product to test it but it seems to use the default layout. Of course, I have made some modifications to check it works.
Do I need to create a new controller to manage this? How does it work?
Any help would be much appreciated.
Cheers
You will either need to create a new controller file or to use the already created product controller file to assign your new template along with it. However, if you decide to use the product controller file for integration, then better to do it from VQMod on this one though so not to affect core files for upgrade purposes in the future.Do I need to create a new controller to manage this? How does it work?
Dedication and passion goes to those who are able to push and merge a project.
Regards,
Straightlight
Programmer / Opencart Tester
Hi Straightlight,
Thanks for the response. I am fairly new to open cart but an experienced programmer. Is VQMod the way to go when making modifications to core files?
Cheers
Chris
Thanks for the response. I am fairly new to open cart but an experienced programmer. Is VQMod the way to go when making modifications to core files?
Cheers
Chris
Yes, definitely. The only thing you need to assure is not to encounter conflict between XML file initialization from either same or different distributors.
Dedication and passion goes to those who are able to push and merge a project.
Regards,
Straightlight
Programmer / Opencart Tester
Hi Straightlight,
Found some VQMod info and reading through it now. Exciting times
Thanks for your help
Chris
Found some VQMod info and reading through it now. Exciting times
Thanks for your help
Chris
anyone figure this out? custom product layouts would make opencart even more epic than it already is!
My Extensions
OpenCart Developer (OCD) Tools
Donate - If I ever helped you.
There is an extension in the store for custom category and product layouts, though it had some issues and I had to manually assign the layouts in the database to make it work. Not sure if this has been fixed now or not.
Running Opencart v3.0.3.2 with multi-stores and the default template from https://www.labeshops.com which has links to all my stores.
Then what is the design tab used for when editing a product? I created a new layout and assigned the product to it but the default product controller keeps loading. If there is no use for the design tab to allow different product layouts remove this feature all together.
Very frustrating...
Very frustrating...
My Extensions
OpenCart Developer (OCD) Tools
Donate - If I ever helped you.
On another note: Deleting the header tags on top of any .tpl file for page editing breaks the whole page. This is because the header tag calls the styles for all the pages. This makes it harder if not impossible to highly customize a page that does not need a header (or even footer for the footer tag) in every page.
This is why developers still use wordpress. They use wordpress and use cart plug-ins (opencart being the least used). If this issue is resolved OpenCart would expand greatly, not only as a shopping cart but a full fledged/full featured Web designing CMS that would have people saying "wordpress what?"
Just my $.02
This is why developers still use wordpress. They use wordpress and use cart plug-ins (opencart being the least used). If this issue is resolved OpenCart would expand greatly, not only as a shopping cart but a full fledged/full featured Web designing CMS that would have people saying "wordpress what?"
Just my $.02
My Extensions
OpenCart Developer (OCD) Tools
Donate - If I ever helped you.
Who is online
Users browsing this forum: stefansmith129 and 185 guests