fimkap Posted November 21, 2017 Share Posted November 21, 2017 Hello, I'm writing a payment module. I noticed that it is initialized only when adding a product to cart. Is there any way to initialize the module before that? In fact, I need my code to run when in product info page and even in the index with product listing. That means before adding any product to the cart. Thanks Quote Link to comment Share on other sites More sharing options...
fimkap Posted November 21, 2017 Author Share Posted November 21, 2017 (edited) I have added a log printing to the initialization routine and saw it called when opening shopping cart (adding to cart) and there's also some code that relates to payment modules and initialization in shopping_cart.php. So I was saying that based on this. Anyway, what I need to do is to add some JS code to the product info page. Let's say we need to enable social sharing of a product. After looking at the modules available maybe the solution will be to add another module to header tags. Then I will be able to do what I need, I guess. What do you think? thanks Edited November 21, 2017 by fimkap adding some more info Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.