• Posts: 195
  • Thank you received: 13
2 months 2 weeks ago #355312

-- HikaShop version -- : 5.0.0
-- Joomla version -- : 4.3.4
-- PHP version -- : 8

i have a custom.js file in my project
in checkout page, after changing payment method , all functions in my own js file doesn't work anymore

how can I fix this ?

Last edit: 2 months 2 weeks ago by khashiz.

Please Log in or Create an account to join the conversation.

  • Posts: 80502
  • Thank you received: 12830
2 months 2 weeks ago #355328


I don't know.

Maybe you could provide a copy of this custom.js and more information on what it is supposed to do, and what doesn't work after the payment method is changed ? That way, I would have more context to tell you what's wrong.

Not knowing anything at what you did, I suppose that you must be adding event listeners on elements on the checkout, but when you change the selected payment method, the HTML where you added your event listeners is refreshed with new HTML from the server, and thus your events listeners are not triggered anymore since it's not the same HTML anymore. In that case, you need to register yourself to the events of the checkout to rebind your event listeners when the HTML changes:

Please Log in or Create an account to join the conversation.

Time to create page: 0.055 seconds
Powered by Kunena Forum