Page 1 of 1

Clone style of existing module?

Posted: Tue Jul 05, 2016 7:31 am
by Bradyn
Hey guys,

I have a latest module and a bestseller module, both of which display products that I'm assuming are pulled from the database with a query, but I'd like them to be displayed the same way. How can I modify the latest module to match the style of the bestseller module or just copy the bestseller module and copy/edit the code where it pulls the information?

I know a bit of coding, mainly C#, so php isn't quite greek to me but I haven't been able to figure out which file this information is in/where specifically it's getting it's products.

OpenCart Version 2.1.0.1.

Re: Clone style of existing module?

Posted: Wed Jul 13, 2016 9:48 am
by straightlight
Welcome to Opencart forum. This documentation may be useful to start developing new modules: http://docs.opencart.com/developer/module/

Re: Clone style of existing module?

Posted: Sat Jul 30, 2016 10:10 pm
by Bradyn
I've attempted to copy the style by using the tpl for the original module in /var/www/catalog/view/theme/(THEME)/template/module/ and it sort of works (but not really) for one module and breaks the other. What other things should I be looking to do to get the style copied over?

Re: Clone style of existing module?

Posted: Sat Jul 30, 2016 10:12 pm
by straightlight
Bradyn wrote:I've attempted to copy the style by using the tpl for the original module in /var/www/catalog/view/theme/(THEME)/template/module/ and it sort of works (but not really) for one module and breaks the other. What other things should I be looking to do to get the style copied over?
Could you explain the step-by-step process that you did?

Re: Clone style of existing module?

Posted: Mon Aug 01, 2016 9:46 am
by moneycarlo