Select menu on change event does not work when more than one form element exists in the form

Wappler Version : 6.5.4
Operating System : Windows 11
Server Model: PHP
Database Type: MySql
Hosting Type: PHP MySql Plesk

Expected behavior

What do you think should happen?

Changing a value in the select menu it should update a cookie value

Actual behavior

What actually happens?
If the select menu is the only element in the form, it works as it should.
Example

<form>
                <select dmx-bind:options="get_blog_list.data.query" optiontext="blog_title" optionvalue="blog_id" dmx-on:changed="cookies1.set('blog_selected',selectedValue,{})" dmx-on:updated="cookies1.set('blog_selected',selectedValue,{});get_current_blog_link_.load({id: cookies1.data.blog_selected},true)">

                </select>
            </form>

BUT WITH ONE MORE ELEMENT IN THE FORM, IT WON"T

<form>
                <select dmx-bind:options="get_blog_list.data.query" optiontext="blog_title" optionvalue="blog_id" dmx-on:changed="cookies1.set('blog_selected',selectedValue,{})" dmx-on:updated="cookies1.set('blog_selected',selectedValue,{});get_current_blog_link_.load({id: cookies1.data.blog_selected},true)">

                </select>

<div class="form-group mb-3">
  <input type="text"  required="">
</div>

            </form>

How to reproduce

Create a simple form with a select menu inside and a dmx-on:updated event and test if it works.

Then add one more element in the form (a text input for example), and test the form again.

Hmmm, I can't reproduce it. Are you getting any errors n the console?

1 Like

First of all thank you for the vid!
I tried it so many times. Let me check again.
Thanks!

Unchecked runtime.lastError: The message port closed before a response was received.

Is the only error I get

Check this link

Tried the above link in icognito mode and it worked...

Maybe you need to clear your cookies. Works fine on my end.

Tried with another browser and it worked again... Oh my, it might be my Chrome's issue... maybe an extension...

Oh I did, I have been trying this for hours.... wow.... thank you so much for helping me out..

1 Like