Dynamic drop down list in jsp
Hi -
I have written a piece of code to dynamically include data in the drop down list after querying the data base. I can print the values using out.print().. but they do not show up in the drop down list. Below is the code -
Please lemme know the mistake i am committing. Thanks you!
<form name="browse" method = "POST">
<select name="uid">
<%
//out.write("before vec");
unit.setCid(user.getCid());
Vector unitNumbers = unit.getUnitNumbers();
ListIterator iter1 = unitNumbers.listIterator();
while ( iter1.hasNext() ){
Integer num = (Integer)iter1.next();
// out.print(num.intValue());
// out.print("Hellooooooooo");
%>
<options> <%= num.intValue() %>
<% }
%>
</select>
</form>
The correct tag should be <option value="val">Val</option>, like this:
<form name="browse" method = "POST">
<select name="uid">
<%
unit.setCid(user.getCid());
Vector unitNumbers = unit.getUnitNumbers();
ListIterator iter1 = unitNumbers.listIterator();
while ( iter1.hasNext() )
Integer num = (Integer)iter1.next();
%>
<option value="<%= num.intValue() %>"><%= num.intValue() %></option>
<% } %>
</select>
</form>
Similar Messages
-
Dynamic drop down list in jsp,javascript!!
Hi,
I want to generate dynamic drop list for country,state & city drop downs.Depends upon the country Id the states have to be list out & depends upon the state & country Id ,i have to get the cities.
I am using jsp,servlets & javascript & my browser is Iceweseal.It should work in firefox & other browsers also.I want someone guidance for this.I can't use xmlHttp.
so can any one tell the procedure & tel me the codings for this.
Itz very urgent...
Plz help me friends...I've answered this countless times before: [http://google.com/search?q=populate+dropdown+balusc+site:sun.com]
One of the answers: [http://forums.sun.com/thread.jspa?threadID=5370149]. -
How to populate data from dynamic drop down list to the text field
Hi,
I tried to populate data from dynamic drop down list to city field. I would like to concat data from drop down list.When selecting add button to add the item and select item from drop down list, data should be displayed in the text field. However, Please help. I spent alot of time to make it works I am not successful.
Please see the link below.
https://acrobat.com/#d=SCPS0eVi6yz13ENV0cnUdw
Thanks for your help
CindyHi Rosalin,
Loop the hidden table, get the values and populate drop down in each iteration.
DropDownList1.addItem("Text","Value");
You can use one more solution for this scenario. If it is a matter of 2,3 dropdowns, put three dropDowns in the form layout and give seperate static data binding to them. At run time make the dropDowns hide/visible as per the requirement.
Hope this helps.
Thanks & Regards,
Sanoosh -
Dynamic Drop-down list - selected value can't be cleared ...
1. check out the following code of a dynamic drop down list using cursor :-
DECLARE
-- DROP-DOWN LIST OF ALL DEPARTMENTS
TEMPNUMBER NUMBER(2) := 2 ;
-- Because we've to initialize the list
-- at least with 1 item.
CURSOR C_DEPT IS
SELECT DEPT_ID FROM DEPARTMENT;
BEGIN
ABORT_QUERY ;
CLEAR_LIST('DEPTLIST');
FOR TEMP IN C_DEPT LOOP
ADD_LIST_ELEMENT( 'DEPTLIST', TEMPNUMBER, TEMP.DEPT_ID, TEMP.DEPT_ID );
:SRBLOCK.LST := TEMP.DEPTNO;
-- prev. line set the newly selected value
TEMPNUMBER := TEMPNUMBER + 1 ;
END LOOP;
END;
2. problem is as we've to atleast initialize with one list item... that item can't be cleared with CLEAR_LIST.
3. how can i actually clear that and still use cursor. because i've searched forum for this thing and found all those code not working ... for my project ...
4. quick help needed ...Hi Omar,
I have solution for you
To populating or refreshing the lists you can use
two procedures:
One of them - generic, which can be used for all types of list
Another is specific which contain a SQL statement to retrieve the data for
particular list.
1. Specific procedure:
PROCEDURE GET_DEPARTMENT_LIST
IS
sql_stat VARCHAR2(32767);
ret_code NUMBER;
BEGIN
-- SQL Statement for Drop-down List
-- (must have two columns for label and value - both VARCHAR2)
sql_stat := ' SELECT DEPARTMENT_NAME,TO_CHAR(DEPT_ID)'
||' FROM SCHEMA.DEPARTMENT';
POPULATE_MY_LIST('BLOCK.DEPARTMENT_LIST',sql_stat,ret_code);
END;
2. Generic procedure:
PROCEDURE POPULATE_MY_LIST
(item_name VARCHAR2,
sql_stat VARCHAR2,
out_code OUT NUMBER)
IS
rg_id RECORDGROUP;
rg_name VARCHAR2(100);
ret_code NUMBER;
item_id ITEM;
BEGIN
item_id := FIND_ITEM(item_name);
IF ID_NULL(item_id) THEN
out_code := -1;
RETURN;
END IF;
--Creating Record Group with Unique Name
rg_name := 'RG_'||SUBSTR(item_name,INSTR(item_name,'.',1)+1,LENGTH(item_name));
--Checking Record Group Name for existance
rg_id := FIND_GROUP(rg_name);
--If Group does exist - delete it
IF NOT ID_NULL(rg_id) THEN
DELETE_GROUP(rg_id);
END IF;
--Creating Record Group
rg_id := CREATE_GROUP_FROM_QUERY(rg_name,sql_stat);
ret_code := POPULATE_GROUP(rg_id);
IF (ret_code <> 0) THEN
out_code := ret_code;
RETURN;
END IF;
POPULATE_LIST(item_name,rg_id);
IF NOT FORM_SUCCESS THEN
out_code := -2;
RETURN;
ELSE
out_code := 0;
END IF;
DELETE_GROUP(rg_id);
END;
Hope it help.
Dmitry -
Dynamic drop down list in Adobe forms
I have created a drop down list using enumerated drop down list from webdynpro native tab and binded in the object palette by giving $record.sap-vhlist.DESCR\.DATA\.FIELD.item[]* in the list items dynamically.DESCR is the field in the internal table into which i fetched data from the database table .I have written this code in a BADI.I dont know whether my form's display type is activex or native? I am not getting any values in the drop down list.can anybody please tell me what might be missing and how should i know whether my form is ActiveX or Native?
My form is called from portal so i have used BADI to connect portal to formHi sarang,
I have done a dynamic drop down list in which DESCR field comes from database table and pops into the drop down dynamically. I was working for a PCR scenario so the adobe form was called from portal.I will tell u all the required steps.It might work for u as it is working for me:
1.In the form:
I used two elements from library first is a "ENUMERATED DROP DOWN LIST NO SELECT" from web-dynpro native tab and second is "ISR_TEXT DISPLAY INVISIBLE ON EDIT MODE" from ISR controls tab.Place them one on other inthe form.
For drop down list the setting are:
In object, field tab click on list items there in ITEMS put :$record.sap-vhlist.DESCR\.DATA\.FIELD.item[*].in ITEMS TEXT write text in ITEMS KEY write key.
In binding,in default binding put $record.DESCR.DATA[*].FIELD.
For text element the settings are:
In binding,default binding put Normal.
when we select ISR_TEXT DISPLAY INVISIBLE ON EDIT MODE it automatically comes with calculated read only int he value tab.so open script editor and place the below code:
$record.DESCR.DATA.FIELD (in calculate).
2.Now the code in BADI is as follows:
In BADI we have to write the code for drop down list in the METHOD "SCENARIO_SET_ADDITIONAL_VALUES"
As i didnt change the standard BADI i added an enhancement spot in which i wrote a function module which fills ADDITIONAL_DATA. and the below code fills the ADDITIONAL_DATA .
DATA: t_t572b TYPE STANDARD TABLE OF t572b WITH HEADER LINE,
t_t554t TYPE STANDARD TABLE OF t554t WITH HEADER LINE.
SELECT * FROM t572b INTO TABLE t_t572b WHERE sprsl EQ 'E'.
CLEAR ls_additional_data-fieldindex.
LOOP AT t_t572b.
ADD 1 TO ls_additional_data-fieldindex.
ls_additional_data-fieldname ='DESCR_KEY'.
ls_additional_data-fieldvalue = t_t572b-descd.
APPEND ls_additional_data TO additional_data.
ls_additional_data-fieldname ='DESCR_LABEL'.
ls_additional_data-fieldvalue = t_t572b-descr.
APPEND ls_additional_data TO additional_data.
CLEAR t_t572b.
ENDLOOP.
For DESCR field the we have to declare DESCR_KEY and DESCR_LABEL in the place holders for key values and palce holders for default values in characteristics tab(where all the fields for the form are defined) of ur respective scenario.(where ur pcr scenario is defined)
Hope ur problem got resolved.
Please let me know if any doubts.
If ur form is not called from portal and u want a dynamic drop down list the difference is put a data drop down list and in object, field tab click on list items there in ITEMS select the field into which u populated the data from the database table (this code shud be written in code Initialization in the respective interface) and in ITEMS TEXT put $ in ITEMS KEY put $.and in binding as we normally do bind it to the respective field in which the data is populated from database table.
It should work. -
Cteate 2 Dynamic drop down list
Hi all
i want to create 2 dynamic drop down list using struts and hibernate
i want the first one to display countries name then if i select a country name the second drop down list will automatic display the country cities .
i'm using database here and my tables like that :-
country table
country_id number(3) pk
country_name varchar(50)
city table
city_id number(5) pk
country_id(3) fk references country(country_id)
city_name varchar(50)
thank you in advanceHi Omar,
I have solution for you
To populating or refreshing the lists you can use
two procedures:
One of them - generic, which can be used for all types of list
Another is specific which contain a SQL statement to retrieve the data for
particular list.
1. Specific procedure:
PROCEDURE GET_DEPARTMENT_LIST
IS
sql_stat VARCHAR2(32767);
ret_code NUMBER;
BEGIN
-- SQL Statement for Drop-down List
-- (must have two columns for label and value - both VARCHAR2)
sql_stat := ' SELECT DEPARTMENT_NAME,TO_CHAR(DEPT_ID)'
||' FROM SCHEMA.DEPARTMENT';
POPULATE_MY_LIST('BLOCK.DEPARTMENT_LIST',sql_stat,ret_code);
END;
2. Generic procedure:
PROCEDURE POPULATE_MY_LIST
(item_name VARCHAR2,
sql_stat VARCHAR2,
out_code OUT NUMBER)
IS
rg_id RECORDGROUP;
rg_name VARCHAR2(100);
ret_code NUMBER;
item_id ITEM;
BEGIN
item_id := FIND_ITEM(item_name);
IF ID_NULL(item_id) THEN
out_code := -1;
RETURN;
END IF;
--Creating Record Group with Unique Name
rg_name := 'RG_'||SUBSTR(item_name,INSTR(item_name,'.',1)+1,LENGTH(item_name));
--Checking Record Group Name for existance
rg_id := FIND_GROUP(rg_name);
--If Group does exist - delete it
IF NOT ID_NULL(rg_id) THEN
DELETE_GROUP(rg_id);
END IF;
--Creating Record Group
rg_id := CREATE_GROUP_FROM_QUERY(rg_name,sql_stat);
ret_code := POPULATE_GROUP(rg_id);
IF (ret_code <> 0) THEN
out_code := ret_code;
RETURN;
END IF;
POPULATE_LIST(item_name,rg_id);
IF NOT FORM_SUCCESS THEN
out_code := -2;
RETURN;
ELSE
out_code := 0;
END IF;
DELETE_GROUP(rg_id);
END;
Hope it help.
Dmitry -
How to create Dynamic Drop down list ?
Hi experts
I want to create a Dynamic Drop down list that should be an Editable,after editing that i need to save.
thanks,
vikram.c.Hello,
Please go through this link:
https://www.sdn.sap.com/irj/sdn/wiki?path=/display/vc/linking%2bdrop-down%2blists
If useful reward.
Vasanth -
Dynamic drop down list with dynamic sql
Hi all,
I am facing a problem here..Please see if any one can help.
I jave a JSP page which has two drop down list boxes.
One list box is populated from the databse.
ListBox1:
values: kishan
maha
tony
assuming all those were populated from database.
ListBox2:
values: Chennai
Bangalore
Hyderabad
should come if "kishan" is selected from the first listbox.
if "maha" is selected then
Values: Delhi
Goa
Mumbai
should be populated from the databse using the where condition
got by the first selection.
Both these boxes are in same page and i do not want to transfer
this to another page..staying in the same how to accomplish this.
An onChange function of the selection list on listBox1 can be
written which gives me what value is selected. This i can get in
Java script. But how to give this value to a jsp variable which
queries the database using the selected value.
Is there any other logic i can use.
remember there is no request that is passed. both are in same page and on selection it should stay in same page populating the
second one dynamically.Bcoz what i have said is the operation in one row.. the same should happed for 5 rows in a form so.. pls send me code if possible or links related to this problem
please help.You can use Ajax ;-) or you do a server roundtrip (aka postback) i.e. the onchange event of ListBox1 submits the form and the server returns the same page with the updated ListBox2
-
Getting problem in hiding drop down list in jsp pages
Hi All,
I have a jsp in which i created a tabbed panel & put 3 forms .
1 of the form contains 3 drop dwom list & few text boxes.
All 3 forms are inside <div> tags .
Clicking on any one of the tab corresponding form is getting displayed with all its form fields hiding other 2 form fields.
but problem is coming with 1 form having drop down list.
all its field get hidden except these drop down list.
i am using following script to hide other forms
function showit(tab){
if(tab == "tab1stuff"){
document.getElementById('tab1stuff').style.zIndex="2";
document.getElementById('tab2stuff').style.zIndex="1";
document.getElementById('tab3stuff').style.zIndex="1";
document.getElementById('tab4stuff').style.zIndex="1";
else if(tab == "tab2stuff"){
document.getElementById('tab2stuff').style.zIndex="2";
document.getElementById('tab1stuff').style.zIndex="1";
document.getElementById('tab3stuff').style.zIndex="1";
document.getElementById('tab4stuff').style.zIndex="1";
else if(tab == "tab3stuff"){
document.getElementById('tab3stuff').style.zIndex="2";
document.getElementById('tab1stuff').style.zIndex="1";
document.getElementById('tab2stuff').style.zIndex="1";
document.getElementById('tab4stuff').style.zIndex="1";
}Plz help me in this regard.
I used style.visible="false" but that is not working here.
Thanks in advance.Thanks you very much.
Now I am using javascript
if(tab == "tab1stuff"){
document.getElementById('tab1stuff').style.visibility="visible";
document.getElementById('tab2stuff').style.visibility="hidden";
document.getElementById('tab3stuff').style.visibility="hidden";
document.getElementById('tab4stuff').style.visibility="hidden";
} Its working ..Earliar it was PHP script. -
Dynamic Drop-Down list in a table row or subform
Hi,
I need to display multiple drop-down list elements dynamically. Each of these DDLs will have different values.
For example:
The table will have 2 columns (Student Name text field and Courses drop-down)
Row 1: Student 1 & Courses of Student1 in DDL
Row 2: Student 2 & Courses of Student2 in DDL
When I execute my app, both the drop-downs (i.e. for both the students) are displaying all the courses of all the students. I tried a lot with binding options..
$record.Students[].Courses[]
is refering to all elements of the node. If I use the index 0 for Students node, I am getting 1st element rows.. if I use 1, I am getting 2nd element rows,,,
But How can I set the binding so that Row 1 has only Student 1 courses and Row 2 has Student 2 courses?
IS THERE A WAY TO DYNAMICALLY SET THE BINDING USING JAVASCRIPT?
I tried with tables, subforms.. it is not working. It is working fine in plain web dynpro table but not in an interactive form. I am using NW 2004s SP11, Web Dynpro Java. LiveCycle Designer 7.1, Adobe Reader 7.09.
There are some other posts talking about similar issue.. I tried the solutions mentioned there as well, but nothing worked.
I would really appreciate if any one can provide a solution or pointer to my problem.
Thanks
RamHey. Uh, this probably isn't the answer you were looking for, but it sounds like you've got a problem with your database design there. Generally speaking, your tables shouldn't have multi-valued fields, in the relational model anyway (sql). Instead, you should look at adding a separate table like EMPLOYEE_HOBBIES. Then you have a foreign key using the employees primary key as the foreign key in the employee_hobbies table, see what I mean? I might have misunderstood your explanation though, I'm not sure.
Alternatively, you could just have hobbies as a big freeform varchar field, and don't bother to make people separate their hobbies into different fields (you'd have to abandon the drop-down listbox idea in this case). If there's no really important reason to make the distinction, then it's probably easier just to not do it. -
How to add a dynamic drop down list in RDLC reports in WPF
I have to Load an RDLC report in WPF application and need to include a drop down list in report.Based on the selection of drop down list different reports to be generated.I am using C# and WPF.
Eg: I have to list the details of employees in in RDLC report.There is a country drop down list, Based on the selection of country drop down list we need to display details of employees in the selected country.Looking good.
With rdlc I think you will have to use the windows report viewer control.
If this was SAP crystal reports there's a wpf report viewer.
I never actually tried that with rdlc and I suppose there is a small chance they turn out to be compatible.
If you have questions on rdlc specifically then you're probably better finding a forum specialises in that. Not sure where that would be but maybe in the sql server forums. It's a business intelligence thing and people who do the likes of ssis are
what you want really.
I do reporting myself but I think you'll find few others who do so here.
Good luck.
Hope that helps.
Recent Technet articles:
Property List Editing;
Dynamic XAML -
Dynamic table with dynamic drop-down list values
Hi,
I need to display a dynamic table with 2 columns on an interactive form.
My Context is defined as below:
Root
StudentData 0..n
StudentName
StudentCourses 0..n
Text
Value
The 1st column should display student name, 2nd column should display student courses. The courses will be different for each student. I populated the context properly. I checked it by printing them. My DDL is bound to "Student Courses".
When there is one row -> The DDL is populated with the courses of student 1 (as there is only one).
When there are more rows -> The DDLs for all the students are populated with all the courses of all the students.
I want to see the data populated like:
TEXTFIELD DROP-DOWN LIST
Student 1------Student1-Course1
Student1-Course2
Student1-Course3
Student 2------Student2-Course1
Student2-Course2
Student2-Course3
I tried to do this in plain web dynpro using SVS.. it is also working similarly.
I have set the singleton property of nodes "StudentData" and "StudentCourses" to false.
Could any one tell me where I am going wrong?
Thanks
RamRam,
I'm not sure how much this will help, but I know I had the same problem as you when I tried to get a similar thing working, but I can't remember which of the many changes I made fixed the problem, so I'll just show you my code and perhaps you can see if anything is different than yours.
Here's where I'm creating my dropdown - in my case EastNew_RegOut is the same as your StudentData, and RateTypeDropValues is the same as your StudentCourses (the comments in the code are not meant to sound bossy to you, this is actually an example piece of code that other developers in my company "steal", so I have to put very specific instructions in there!):
int nodeSize = wdContext.nodeEastNew_RegOut().size();
for (int i = 0; i < nodeSize; i++) {
//create an element called "table", that's the element at i. So, basically it's a row. Maybe I should have
//called it "row" instead of table.
IPublicDeviceExchange.IEastNew_RegOutElement table = (IPublicDeviceExchange.IEastNew_RegOutElement)wdContext.nodeEastNew_RegOut().getElementAt(i);
//this line of code just executes an rfc that finds out what rates need to be in the dropdown for this particular row
executeRateTypeDropdown(rateCategory, table.getNum(), wdContext.currentEastNew_MeterOutElement().getReggrp());
//clear out what's already in there before we re-populate it.
table.nodeRateTypeDropValues().invalidate();
//now, I'm looping through all the values in the *actual* rate type dropdown (the one that's an RFC, populated by the above "execute" method)
for (int j = 0; j < wdContext.nodeEastRatetype_DropdownOut().size(); j++) {
//for each element in the *actual* Rate type dropdown, I'm going to create an element in my node that I created
//and set the values from the *actual* one as the values in my node.
IPublicDeviceExchange.IRateTypeDropValuesElement element = wdContext.createRateTypeDropValuesElement();
IPublicDeviceExchange.IEastRatetype_DropdownOutElement rateTypeOut = (IPublicDeviceExchange.IEastRatetype_DropdownOutElement)wdContext.nodeEastRatetype_DropdownOut().getElementAt(j);
element.setText(rateTypeOut.getText());
element.setValue(rateTypeOut.getRatetype());
//here's another key - notice how I don't say wdContext.nodeRateTypeDropValues() - it's the one that's
//directly off that table I created earlier - the thing that's essentially a row in my newReg table.
//So, what I'm doing here is adding that new element I created to the dropdown FOR THAT ROW!
//(btw, if you're trying to duplicate this, and this method does not exist for your "table" object, it's
//probably because you didn't listen to me above and you didn't create your node with the singleton property
//set to false.)
table.nodeRateTypeDropValues().addElement(element);
As for my layout... my table is bound to the EastNew_RegOut node, and the column with the dropdown is bound to RateTypeDropValues.Value (that's probably obvious, but there you have it anyway)
Finally, in my context, EastNew_RegOut is singleton = true (I was surprised about this, actually, I would have assumed it was false) with a selection of 0..1 and RateTypeDropValues has singleton set to false with a selection of 0..1
I hope that helps to some degree!
Jennifer -
How to display information from database using drop down list in JSP?
Hi all.
Like the tile above suggest, I'm having difficulty in obtaining the data as well as displaying them in a drop down list.
For example: If i were to have the following in my database:
SerialNo Food
1 Bread
2 Milk
3 Butter
The drop down list should look like the following:
[Bread][\/]
[Milk]
[Butter]
How do i go around coding it in JSP?
Thanks in advance.
C.KHai Please try the following code
You have to make some changes according to your system i am using
MSSqlserver Driver change the class name and the connection string
for your need
<HTML>
<HEAD>
<%@ page language="java" import="java.sql.*"%>
<LINK href="../theme/Master.css" rel="stylesheet" type="text/css">
<TITLE>ListDrop.jsp</TITLE>
<%!Connection con;
%>
</HEAD>
<BODY>
<select>
<%
try {
Class.forName("com.microsoft.jdbc.sqlserver.SQLServerDriver");\\Here you specify the Class Nale
con = DriverManager
.getConnection(
"jdbc:microsoft:sqlserver://javaserver:1433;DatabaseName=karthi",
"sa", "sa");\\here Connection string
ResultSet rs;
Statement st = con.createStatement();
rs = st.executeQuery("select SerialNo,Food from Foods");
while (rs.next()) {
%>
<option value='<%= rs.getString("SerialNo") %>'><%= rs.getString("Food")%></option>
<%
} catch (Exception e) {
e.printStackTrace();
%>
</select>
</BODY>
</HTML> -
Hi Friends,
I am working on a Drop down list in Adobe Interactive Form.
I have a internal table contaning some values, i have binded my dropdown element wiht the field of the table containing the values. Thatu2019s working fine an I can select on value from the drop down list.
I want to add a new value to select another value from the drop down list or delete it.
The scenario is that when I click on add-Button to selects another value from the drop down list in subform, I add another Drop down list, but I canu2019t open the second or third drop down to select the value.
Iu2019m a new in JavaScript. I thing a missing something in JavaScript, wenn I click add-Button
Please let me know what is missing or send me an exampel.
Thanks and Regards.Hi Chintan,
Thank you for your help.
I will try to explain more clearly my problem .
In my case, my form will be used in ABAP system without any web dynpro applicatoin . forms are send by mail and retrieve by mail in SAP .
I define a PDF forms in the ABAP stack of SAP . in the form i create a table subforms , number of rows depend on what is store on the database.
In the fact, my field is defined as dropdownlist box and value are link to the content of the interface attributes .
For thr first row that works fine but when i add a line, the content is not populate automaticaly, and i can' t open the dropdownlist.
When user receive the forms, he can add lines to the table while it's define as dynamic. My problem is that on NEW LINE the dropdownlist box is empty.
How can i solved this issue ?
Tanks -
Dynamic Drop Down List Trouble in Dreamweaver
I am having trouble with Dreamweaver 8 and php with MySQL.
Basically, I have a main page, index.php that includes a
header file that I use to display my header using readfile like
this:
<?php readfile("header.php"); ?>
Inside of header.php, there is code to create a drop down
list. I am trying to populate this list from my database, but I
cannot get this to work.
This is the code snippet:
<form name="storeShowSelect" method="GET"
class="sf_select" target='newwin'>
<input name="selectStore" type="hidden" value="17999">
<select name="storeSelect"
onChange="jumpToLink(this);">
<option disabled selected >--- Select a store
---</option>
<?php
do {
?>
<option value="<?php echo
$row_marketplaceStoreNames['storeName']; ?>">
<?php echo
$row_marketplaceStoreNames['storeDisplayName']; ?>
</option>
<?php
} while ($row_marketplaceStoreNames =
mysql_fetch_assoc($marketplaceStoreNames));
?>
</select>
</form>
It looks like this is only inserting one blank row in the
drop down list. When testing my recordset in Dreamweaver, I do get
the rows of data that I am expecting.
Can anyone possibly help me figure out what I am doing wrong
here?
Thanks in advance,
MonaI am having trouble with Dreamweaver 8 and php with MySQL.
Basically, I have a main page, index.php that includes a
header file that I use to display my header using readfile like
this:
<?php readfile("header.php"); ?>
Inside of header.php, there is code to create a drop down
list. I am trying to populate this list from my database, but I
cannot get this to work.
This is the code snippet:
<form name="storeShowSelect" method="GET"
class="sf_select" target='newwin'>
<input name="selectStore" type="hidden" value="17999">
<select name="storeSelect"
onChange="jumpToLink(this);">
<option disabled selected >--- Select a store
---</option>
<?php
do {
?>
<option value="<?php echo
$row_marketplaceStoreNames['storeName']; ?>">
<?php echo
$row_marketplaceStoreNames['storeDisplayName']; ?>
</option>
<?php
} while ($row_marketplaceStoreNames =
mysql_fetch_assoc($marketplaceStoreNames));
?>
</select>
</form>
It looks like this is only inserting one blank row in the
drop down list. When testing my recordset in Dreamweaver, I do get
the rows of data that I am expecting.
Can anyone possibly help me figure out what I am doing wrong
here?
Thanks in advance,
Mona
Maybe you are looking for
-
"Custom" grouping and / or colored lines in ALV
Hi! Two questions: 1. Is it possible to use colors in the ALV for a given set of rows? I'd like to mark rows with a color, which are logically belongs together. 2. Other approach would be to sort the ALV and via that the "similar" rows (i.e. some col
-
Srw.run_report desformat=pdf, output is missing
Hi, Could someone please help me with the following: I have 2 reports, rep1.rdf and rep2.rdf. rep1.rdf has a formula column in which I invoke rep2.rdf with the following syntax: srw.run_report('report=rep2.rdf '|| ' destype=file'|| ' desname=test.pdf
-
SFTP MGET of large files fails - connection closed - problem with spool file
I have a new SFTP job to get files from an FTP Server. The files are large (80mg, 150mg). I can get smaller files from the ftp site with no issue, but when attempting the larger files the job completes abnormally after 2 min 1 sec. each time. I ca
-
Hello. Here is described how to use different codecs for different clients (Sorenson Spark for Flash Player 7- and On2 VP6 for Flash Player 8+). http://livedocs.adobe.com/fms/2/docs/00000081.html But as I can see, it is only suitable for recorded .fl
-
Export trans image in PS CS5 help
I've moved from photoshop 7.0 to CS5 extended 12.5 in a single bound. To export a transparent image in ps7 you just wentto the help menu and selected 'export transparent image'.... can you please tell me where this feature is in the new ps cs5 extend