jQWidgets Forums
Forum Replies Created
-
Author
-
February 6, 2012 at 5:00 pm in reply to: How to use TreeView checkbox with a web form How to use TreeView checkbox with a web form #2015
Sorry, I was just able to enter the formatted code. id and name of checkbox are not correct, however value is, hope this help my point:
<!-- Lev 1 --><ul style="padding-left:10px;"> <li> <input type="checkbox" id="lev1" name="lev2" value="cat1"> Cat 1 <!-- Lev 2 --> <ul style="padding-left:10px;"> <li><input type="checkbox" id="lev1" name="lev2" value="cat1_sub1"> Sub-Cat 1</li> <li> <input type="checkbox" id="lev1" name="lev2" value="cat1_sub2"> Sub-Cat 2 <!-- Lev 3 --> <ul style="padding-left:10px;"> <li><input type="checkbox" id="lev1" name="lev2" value="cat1_sub2_it1"> Item 1</li> <li><input type="checkbox" id="lev1" name="lev2" value="cat1_sub2_it2"> Item 2</li> </ul><!-- /Lev3 --> </li> </ul><!-- /Lev2 --> </li> <li> <input type="checkbox" id="lev1" name="lev2" value="cat2"> Cat 2 <!-- Lev 2 --> <ul style="padding-left:10px;"> <li> <input type="checkbox" id="lev1" name="lev2" value="cat2_sub1"> Sub-Cat 1 <!-- Lev 3 --> <ul style="padding-left:10px;"> <li><input type="checkbox" id="lev1" name="lev2" value="cat2_sub1_it1"> Item 1</li> <li><input type="checkbox" id="lev1" name="lev2" value="cat2_sub1_it2"> Item 2</li> </ul><!-- /Lev3 --> </li> <li> <input type="checkbox" id="lev1" name="lev2" value="cat2_sub2"> Sub Cat 2 <!-- Lev 3 --> <ul style="padding-left:10px;"> <li><input type="checkbox" id="lev1" name="lev2" value="cat2_sub2_it1"> Item 1</li> <li><input type="checkbox" id="lev1" name="lev2" value="cat2_sub2_it2"> Item 2</li> </ul><!-- /Lev3 --> </li> </ul><!-- /Lev2 --> </li></ul><!-- /Lev1 -->
February 6, 2012 at 4:55 pm in reply to: How to use TreeView checkbox with a web form How to use TreeView checkbox with a web form #2012Peter, thanks for your quick reply.
Please look at the sample code which illustrates what I am trying to achieve:
Cat 1
Sub-Cat 1
Sub-Cat 2
Item 1
Item 2
Cat 2
Sub-Cat 1
Item 1
Item 2
Sub Cat 2
Item 1
Item 2
Basically, I have three levels: can select one Category, which auto select (check) the content below, or drill-down going from generic to specific (Item list, passing through Sub Category).
jqxTree does it very nicely on the UI level, but I still don’t see where to specify the “value” of each item. You mentioned Ajax, and I used it a lot in my applications, however I am stuck on this, can you provide a more detailed example of the Ajax call and scripting file? PHP or any other language you like is fine.Thank you,
Dave -
AuthorPosts