One way to do it would be to trigger a click to this function when the page loads:
UK OpenCart Hosting | OpenCart Audits | OpenCart Support - please email info@antropy.co.uk
Try something like this:
Code: Select all
$(document).ready(function() {
// Trigger the click event on the shipping estimator button when the page loads.
$('#button-shipping').trigger('click');
});
UK OpenCart Hosting | OpenCart Audits | OpenCart Support - please email info@antropy.co.uk
no that's javascript, you put that in the twig file and put <script></script> around it, or imbed it in another script tag. I think you put it in
"catalog/view/theme/default/template/checkout/checkout.twig", at worst case in the footer or header twig in a $(document).ready() code snippet.
"catalog/view/theme/default/template/checkout/checkout.twig", at worst case in the footer or header twig in a $(document).ready() code snippet.
v3.0.3.9 php 8.1
I'm here for a reason, if your response is contact a/the developer, just don't reply.
This is a better solution if it works.nonnedelectari wrote: ↑Thu Sep 12, 2024 8:10 amChange the class from "panel-collapse collapse" to "panel-collapse collapse in" of id "collapse-shipping" in the twig file of that component
UK OpenCart Hosting | OpenCart Audits | OpenCart Support - please email info@antropy.co.uk
Well that changes everything, you should have said that at the start.
UK OpenCart Hosting | OpenCart Audits | OpenCart Support - please email info@antropy.co.uk
well, to be fair it wasn't me that started the thread But i eventually found the file. If anyone else using journal wants to do this it's in /catalog/view/theme/journal2/template/extension/total/shipping.twig . Change line 5 to <div id="collapse-shipping" class="panel-collapse collapse in" aria-expanded="true">
Ah right I see.
Great, marking [SOLVED].
UK OpenCart Hosting | OpenCart Audits | OpenCart Support - please email info@antropy.co.uk
Who is online
Users browsing this forum: Gpli, Majestic-12 [Bot] and 16 guests