Forums

Retrieves html from a read_data from an "on change" dropdown

webcrea 23 Apr, 2018
Hi,

A dropdown with Events like this
On change
Reloads
#nomProduit

When I change in dropdown, i can see in "Network" console the answer with the good code html

How can i put this code in a html div for example.

I tried for "Element(s) identifier" #fc1 where fc1 id the id of a div in custom html
Results : reload full form in div :-(

Regards
healyhatman 23 Apr, 2018
You can make an AJAX function in a custom JavaScript block, and onChange run the function. The url you want is the url.com/form? event=event name&tvout=view

replace /form? With the component url, like index.php?component=chronoforms &form=formname or whatever it is

Have the event return whatever it is you want to display
webcrea 23 Apr, 2018
Thanks healyhatman,

It's already a json. It return html code that i want to put in a div.
healyhatman 23 Apr, 2018
You've got the tools you need it's midnight I'm going to bed🙂 play around with ityoull figure it out.

W3schools or plenty of other resources on Google.
webcrea 23 Apr, 2018
I know but the goal is to use chrono features
Thanks and good night
This topic is locked and no more replies can be posted.

VPS & Email Hosting 20% discount
hostinger