I tried adding <div align="center"> to the start of the ad code, it worked for the banner but also centered everything else on Opencart I have removed that now so the banner is still aligned left.
https://xazzi.co.uk/
Thanks all
OC Version 3.0.3.7 - Debian 10 - ISPConfig
Dedication and passion goes to those who are able to push and merge a project.
Regards,
Straightlight
Programmer / Opencart Tester
Of course. You can either look at the documentation: https://github.com/opencart/opencart/wiki/Events-System or look at the catalog/controller/extension/advertise/google.php file as an e.g on how to build an event from a controller.
Dedication and passion goes to those who are able to push and merge a project.
Regards,
Straightlight
Programmer / Opencart Tester
If you're using a custom theme, common/header.twig works just fine. As for the controller I referred, it's simply an e.g as said above.
Dedication and passion goes to those who are able to push and merge a project.
Regards,
Straightlight
Programmer / Opencart Tester
The answer's already above. Without affecting the layout, you could create an extension module to achieve this. Once the module created, you simply need to assign the module to each layouts in the OC admin. Alternatively, you could use CSS to center your banner in a new class.HenrysCat wrote: ↑Sat Jul 24, 2021 2:11 amOK cool, so how do I center the banner without centering the whole site?straightlight wrote: ↑Sat Jul 24, 2021 2:10 amIf you're using a custom theme, common/header.twig works just fine.
Dedication and passion goes to those who are able to push and merge a project.
Regards,
Straightlight
Programmer / Opencart Tester
Dedication and passion goes to those who are able to push and merge a project.
Regards,
Straightlight
Programmer / Opencart Tester
Now that the issue has been solved, please add: [SOLVED] at the beginning of the subject line on your first post.
Dedication and passion goes to those who are able to push and merge a project.
Regards,
Straightlight
Programmer / Opencart Tester
"Use an event"
"Use an extension"
Both bad suggestions in this case, please be more helpful in future - for example if suggesting an Event, explain briefly how it could apply to this particular case as well as linking to the documentation.
UK OpenCart Hosting | OpenCart Audits | OpenCart Support - please email info@antropy.co.uk
I hope you did this with vQmod or OCMOD and did not modify core OpenCart files or you may break other extensions.
UK OpenCart Hosting | OpenCart Audits | OpenCart Support - please email info@antropy.co.uk
It's a free platform Paul. It's been like that for many years and people have the free will to provide their knowledge on that. Please follow the forum rules. Besides, I don't recall your presence during the weekends.paulfeakins wrote: ↑Mon Jul 26, 2021 5:57 pm@straightlight
"Use an event"
"Use an extension"
Both bad suggestions in this case, please be more helpful in future - for example if suggesting an Event, explain briefly how it could apply to this particular case as well as linking to the documentation.
Dedication and passion goes to those who are able to push and merge a project.
Regards,
Straightlight
Programmer / Opencart Tester
I did it from, Home > Theme Editor > Common > header.twigpaulfeakins wrote: ↑Mon Jul 26, 2021 6:01 pmI hope you did this with vQmod or OCMOD and did not modify core OpenCart files or you may break other extensions.
Was this ok?
OC Version 3.0.3.7 - Debian 10 - ISPConfig
Users browsing this forum: Shiftcom and 409 guests