I attempted the provided solution but unfortunately, it did not yield the desired outcome. Upon checking the HTMX log, it appears that everything is set up correctly. Can anyone point out what mistake I might be making in this scenario?
document.getElementById('plan-id').addEventListener('change', function () {
const selectedPlan = this.value;
const selectedDuration = document.getElementById('duration-id').value;
const url = `change.html?planCode=` + encodeURIComponent(selectedPlan) + `&durationCode=` + encodeURIComponent(selectedDuration);
this.setAttribute('hx-get', url);
htmx.logAll();
htmx.trigger('#plan-id', 'get', { url: url });
});