jQWidgets Forums
Forum Replies Created
-
Author
-
July 17, 2016 at 8:01 pm in reply to: typed Combobox value not being submitted or echoed typed Combobox value not being submitted or echoed #85808
Hello Dimitar,
I can actually submit to the database, and also display values from the databases.
But am still failing to pick values entered/typed(values that dont exists inside the db.) into the combobox.
Values selected are coming from a Jason file. and different table.
So when selected or when a new value is typed, its entered into another table.The fact that i can submit selected values…Means the combobox is within a Form element.
Since i am cascading combos, could the `$(“#emis_no”)<em><strong>.bind</strong><</em>(‘select’, function(event) be the one causing this unusual behaviour..?
`July 15, 2016 at 7:46 am in reply to: typed Combobox value not being submitted or echoed typed Combobox value not being submitted or echoed #85770Hello Dimitar,
I ended up combining the two as seen in the code below;
But still no change or effect to the issue.<script type="text/javascript"> $(document).ready(function () { //start EMIS code var customersSourcel = { datatype: "json", datafields: [ { name: 'Emis_No'}, { name: 'District'}, { name: 'County'}, { name: 'Subcounty'}, { name: 'Parish'}, { name: 'School'} ], url: 'includes/emis.php', cache: false, async: false }; // Create a jqxComboBox var customersAdapterl = new $.jqx.dataAdapter(customersSourcel); $("#emis_no").jqxComboBox( { source: customersAdapterl, width: 200, height: 25, promptText: "emis", displayMember: 'Emis_No', valueMember: 'Emis_No' }); $("#emis_no").bind('select', function(event) { if (event.args) { var index = $("#emis_no").jqxComboBox('selectedIndex'); if (index != -1) { var record = customersAdapterl.records[index]; document.form1.district.value = record.District; $("#county").jqxComboBox({ disabled: false}); document.form1.county.value = record.County; $("#sub_county").jqxComboBox({ disabled: false}); document.form1.sub_county.value = record.Subcounty; $("#parish").jqxComboBox({ disabled: false}); document.form1.parish.value = record.Parish; $("#school").jqxComboBox({ disabled: false}); document.form1.school.value = record.School; } } }); $("#emis_no input").on('keypress', function(event) { var enteredValue = $("#emis_no input")[0].value; if (event.key === 'Enter') { var existingItem = $("#emis_no").jqxComboBox('getItemByValue', enteredValue); if (existingItem === undefined) { $("#emis_no").jqxComboBox('addItem', enteredValue); var item = $("#emis_no").jqxComboBox('getItemByValue', enteredValue); $("#emis_no").jqxComboBox('selectItem', item); } } }); //END EMIS CODE
July 13, 2016 at 7:24 am in reply to: typed Combobox value not being submitted or echoed typed Combobox value not being submitted or echoed #85701I also tried renaming the from (“#emis_no Input”) to just (“#emis_no”) but still values not being captured.
July 13, 2016 at 6:31 am in reply to: typed Combobox value not being submitted or echoed typed Combobox value not being submitted or echoed #85698This is what I have done basing on that example, and still it is not being picked by php.(I mean the typed values.
$(document).ready(function () { //start EMIS code var customersSourcel = { datatype: "json", datafields: [ { name: 'Emis_No'}, { name: 'District'}, { name: 'County'}, { name: 'Subcounty'}, { name: 'Parish'}, { name: 'School'} ], url: 'includes/emis.php', cache: false, async: false }; var customersAdapterl = new $.jqx.dataAdapter(customersSourcel); $("#emis_no").jqxComboBox( { source: customersAdapterl, width: 200, height: 25, promptText: "emis", displayMember: 'Emis_No', valueMember: 'Emis_No' }); $("#emis_no input").on('keypress', function(event) { var enteredValue = $("#emis_no input")[0].value; if (event.key === 'Enter') { var existingItem = $("#emis_no").jqxComboBox('getItemByValue', enteredValue); if (existingItem === undefined) { $("#emis_no").jqxComboBox('addItem', enteredValue); var item = $("#emis_no").jqxComboBox('getItemByValue', enteredValue); $("#emis_no").jqxComboBox('selectItem', item); } } }); //END EMIS CODE
July 13, 2016 at 5:44 am in reply to: typed Combobox value not being submitted or echoed typed Combobox value not being submitted or echoed #85690Hello Dimitar,
Thanks..for this..
But then..the scenario is that I have a jason file pulling data from mysql database table A.
Then the data is selected and displayed on the combobox.
However there are some I also want to add a new values, so I have to type the value into the combobox.
So how do I get either typed value or selected value picked by php and either echoed or submitted to the database.Thank you for your help.
July 12, 2016 at 10:46 am in reply to: how to get the entered text in jqxcombobox how to get the entered text in jqxcombobox #85674I am still having similar problem now.
WHen I edit a value from withing the combobox or type another value into the combobox, the value is not read or submitted.Somebody with the solution please help me.
I have tried chnaging the methods, but nothing is happening.July 12, 2016 at 10:37 am in reply to: typed Combobox value not being submitted or echoed typed Combobox value not being submitted or echoed #85673Hello, I can submit selected. My problem is It cannot submit Typed values.
I can pick values from the database. and select them and then submit.
For example, if a value from the database is misspelt, and i need to edit it..The edited value is not submit where it should go.
Please help.
July 11, 2016 at 4:39 pm in reply to: typed Combobox value not being submitted or echoed typed Combobox value not being submitted or echoed #85650I tried to initialise customers as seen below, but still nothing..instead its just showing now the last record in the database, and when I type, still, the value is not picked/ echoed. Somebody please help.
Thank you
$customers =array();
$customers[] = array( ‘Emis_No’ => $row[‘Emis_No’], ‘District’ => $row[‘District’], ‘County’ => $row[‘County’], ‘Subcounty’ => $row[‘Subcounty’], ‘Parish’ => $row[‘Parish’], ‘School’ => $row[‘School’] ); -
AuthorPosts