full example how to cascading dropdown list

full example how to cascading dropdown list

stancaballerostancaballero Posts: 29Questions: 9Answers: 0

Link to test case:
Debugger code (debug.datatables.net):
Error messages shown:
Description of problem:

This question has accepted answers - jump to:

Answers

  • colincolin Posts: 15,142Questions: 1Answers: 2,586

    I assume you're referring to the Editor dependent() example. We don't have one with cascading lists - but this example does have a select. In the dependent function, you would then use logic to either retrieve new values or modify the existing values using local logic. This example from this thread shows how to amend a select element.

    Colin

  • stancaballerostancaballero Posts: 29Questions: 9Answers: 0

    i mean the second dropdown field is dependent on the 1st dropdown field
    example:
    1st field : Country
    2nd fiels : City

  • colincolin Posts: 15,142Questions: 1Answers: 2,586

    Yep, my advice above would hold. Also, I just remembered this blog post which is also discussing this: https://datatables.net/blog/2017-09-01

    Colin

  • stancaballerostancaballero Posts: 29Questions: 9Answers: 0

    Can you add example under API so that we can clearly understand the entire codes because only "hide and show" example of dependent fields which i downloaded

  • colincolin Posts: 15,142Questions: 1Answers: 2,586
    Answer ✓

    Good idea! I'll add that next week and you'll see it in the examples on the next site rebuild.

    Colin

  • stancaballerostancaballero Posts: 29Questions: 9Answers: 0

    good day sir, i hope you have sample script now because I am waiting in order to continue my project.... thank you in advance :)

  • colincolin Posts: 15,142Questions: 1Answers: 2,586
    Answer ✓

    Not yet, but hopefully by end of the day! I'll report back when ready (it's on my to-do list! :) )

    Colin

  • stancaballerostancaballero Posts: 29Questions: 9Answers: 0

    i got it now sir.... thank you :)

Sign In or Register to comment.