I am not able to display the selected value of my combobox

Ads
 

I am not able to display the selected value of my combobox

  <?php
echo "<select name=\"hello\">\n";
echo "<option value=\"NULL\">Select Value</option>\n";

   $strQuery = "select unitcode,unitname from units order by unitcode";
   $rsrcResult = mysql_query($strQuery);
$i=1;
$select='<select size=1 name="unitcode">';
   while($arrayRow = mysql_fetch_assoc($rsrcResult)) 
   {
     $strA = $arrayRow[$i];
      $strB = $arrayRow["unitcode"];
      $i=$i+1;
      echo "<option value=''>$strB</option>";
      $select.="<option name='unitcode'
value=\"".$myrow['$i']."\">".$myrow['name']."</option>\n";
$i=$i+1;
   }
   $number = $_POST['unitcode'];
echo "The number you selected was: '$number'"; ?>
View Answers

Ads









Related Tutorials/Questions & Answers:
I am not able to display the selected value of my combobox
I am not able to display the selected value of my combobox   <...["unitcode"]; $i=$i+1; echo "<option value=''>$strB</option>"; $select.="<option name='unitcode' value=\"".$myrow['$i
. Display JavaScript dropdown selected value
. Display JavaScript dropdown selected value  How to get the selected value from dropdown box? I am using javascript.   <html> <...("dropdown").value; alert("You selected : " + dropdownValue); } <
Advertisements
Java swing: get selected value from combobox
Java swing: get selected value from combobox In this tutorial, you will learn how to get selected value from combobox. The combobox provides the list... imposed an actionlistener on the combobox in order to get the selected value from
this is my file upload page, here i am not getting tags input field value to my servlet,please suggest a solution?
this is my file upload page, here i am not getting tags input field value to my... + '" type="button" ' + 'value="Remove" onclick = "RemoveFileUpload(this)" />...()" style="height: 27px; width: 74px;" tabindex="25" type="button" value="New
I want to Populate ComBobox value from database that combox is Itemrenderer of DataGrid.
I want to Populate ComBobox value from database that combox is Itemrenderer of DataGrid.  I want to Populate ComBobox value from database that combox is Itemrenderer of DataGrid
how to display textbox value based on selected option value?
how to display textbox value based on selected option value?  Hi,I... on first value I finished above code. ID: xx Name:xx xx is baesd on second and first value. But it is that l can't do that. now, l post my code
i am unable to identify the error in my code
i am unable to identify the error in my code  class Program { public static void main(String[] args) { BufferedReader br=new BufferedReader(new InputStreamReader(System.in)); System.out.println("enter
i am unable to identify the error in my code
i am unable to identify the error in my code  class Program { public static void main(String[] args) { BufferedReader br=new BufferedReader(new InputStreamReader(System.in)); System.out.println("enter
how to select second combobox value .
how to select second combobox value .  I requirement is , i have two combo box, i am selected first combo box value then automatically second combo box value show ,But this both combo box value i retrieves in database. please
this is my code but i cant able to run it wt is the problem
this is my code but i cant able to run it wt is the problem  import java.io.*; class createthread { int thread=4,i; class thread1 extends createthread { public void run() { for(i=0;i
this is my code but i cant able to run it wt is the problem
this is my code but i cant able to run it wt is the problem  import java.io.*; class createthread { int thread=4,i; class thread1 extends createthread { public void run() { for(i=0;i
how to display output on jsp from while loop of action class....actually i am retreiving the post from posts column from my sql.plz help.thnkss
how to display output on jsp from while loop of action class....actually i am retreiving the post from posts column from my sql.plz help.thnkss  how to display output on jsp from while loop of action class....actually i am
How to display data fom MySQL DataBase-table in to JSP file by submitting a value in combobox.
How to display data fom MySQL DataBase-table in to JSP file by submitting a value in combobox.   I have the same problem.plz help me. I have MySQL...; Values(crs,cs 4.0,xxx), Values(sdp,cs 5.0,yyy), Values(air,cs 6.0,zzz), i want
nested selected tag ihave display selected item
nested selected tag ihave display selected item   i have two combo..., ok it can be done by creating array my problem is when i display data like..." , but i want "INDIA", and i use if condition for each value and display by using
I am trying to create domains for column attributes of my data dictionary?
I am trying to create domains for column attributes of my data dictionary?  Please provide me with the best possible solution. I already have the fields and there data types in a table and then the field values in another table
fetch database value to text box based on selected value my code given below pls correct my code
fetch database value to text box based on selected value my code given below pls correct my code  my Code Given below Pls... help me send correct...="destination" onchange="getPrice()"> <html:option value="0">
fetch database value to text box based on selected value my code given below pls correct my code
fetch database value to text box based on selected value my code given below pls correct my code  my Code Given below Pls... help me send correct...="destination" onchange="getPrice()"> <html:option value="0">
How to pass the value of Selected Value of combo box into sql ??
How to pass the value of Selected Value of combo box into sql ??  My...(regno,sname,sgen). Now i want to select one "regno" from Combobox and then after submit i want to display other field. how to get it?? plz help me
this is my javascript code and i am not understanding the mistake in this,please help me?
this is my javascript code and i am not understanding the mistake...="gender" value="Male"> Male <input type="radio" name="gender" value="Female"> Female <br> Enter an Email
I want to display the quantity of the selected item of a drop down list in a textbox. The data is stored in database.
I want to display the quantity of the selected item of a drop down list...; <%=name%> <% } %> // my code for displaying quantity is below but its now working.I am new to jsp, so dont know how
Not able to display jtable at runtime
Not able to display jtable at runtime  Hello, can anyone please help me. I am trying to create a dynamic table with checkboxes. Data are accessed... database properly. But I am not getting why it is not creating the table
I need to display parts of my own website on another website in an iframe
I need to display parts of my own website on another website in an iframe  I need to display parts of my own website on another website in an iframe. please refer me how do i do
autocomplete(): Spring mvc with jquery: I am not getting correct value in the text filed. Please help me
autocomplete(): Spring mvc with jquery: I am not getting correct value... bird names , but whenever i selected any bird in the text filed the am getting... related birds whenever we give input in the text field. But i am getting the wrong
I am creating one jsp page in which I read in a text file, then display that data in tabular format. Now I need to calculate a total.
I am creating one jsp page in which I read in a text file, then display that data in tabular format. Now I need to calculate a total.  I am reading...... } The output displays 4 rows and 2 columns. How can I calculate the total
HOW TO DISPLAY ID IN TEXTBOX BASED ON COMBOBOX SELECTION IN A SAME PAGE
createuser.jsp. There am loading this Rolename into combobox. My question is how to get Roleid in textbox when i select Role_name from combobox in a same...HOW TO DISPLAY ID IN TEXTBOX BASED ON COMBOBOX SELECTION IN A SAME PAGE 
how to display selected checkboxes dynamically using jsp
how to display selected checkboxes dynamically using jsp  Hi friends i have a requirement that : in my JSP page i have radio buttons followed by the DB fields..when i click SUBMIT button,if the field(or record
selected radiobutton to display different page
selected radiobutton to display different page  there are three radio button are there , in that selected button to display different page. when submit it, using struts2 framework . plz help me to how write code
MY Sql Query Error - Not able to Understand the issue
MY Sql Query Error - Not able to Understand the issue  I am new at MYSQL,I wrote simple query as follow: CREATE Table tblFeedBack ( FeedBackID INT... END I am getting an error as follow: Schema Creation Failed: You have an error
Combobox in HTML
Combobox in HTML is used to display a drop-down list of some options from which one can be selected. <select> tag is supported in all the web browsers... the options in the list. Here is how to make a simple Combobox in HTML: <html>
Dynamically display values in dropdown box and then show the selected values as selected by the user which is already stored in the DB
Dynamically display values in dropdown box and then show the selected values..., This is for Updating. I had two SQL queries one for only selected values... trying to display multiple selection selected from the list of all the values
How to Display an alert message when nothing is selected in jspinner in java?
How to Display an alert message when nothing is selected in jspinner in java?  Hello, i'm trying to code a jspinner in java and i want to display a message when nothing is selected. My initial value is 0 min value = 0 max value

Ads