oracle - Insertion of dynamic select list in HTML code in ApEx -
let's make dynamic select list in shared components, , need insert dynamic select list in html code. there method insert in code?
let have following lov name my_lov
:
select 'red' d, 1 r dual union select 'green', 2 dual union select 'blue', 3 dual
its html code be:
<select name="f01" > <option value="%null%" selected="selected">%</option> <option value="1" >red</option> <option value="2" >green</option> <option value="3" >blue</option> </select>
so bit difficult write html manually, can generate html code in pl/sql block. need package apex_item. has number of functions, generate html code of standard elements. select lists can use 1 of following functions:
- select_list
- select_list_from_lov
- select_list_from_lov_xl
- select_list_from_query
- select_list_from_query_xl
in case, need select_list_from_lov
or select_list_from_lov_xl
. need change region type pl/sql
, write following source code region:
begin htp.p(apex_item.select_list_from_lov(p_idx => 1, p_lov => 'my_lov')); end;
also need know: package apex_application
has number of variables names g_fxx
, xx
- number between 1 , 50. these variables used data exchange between server , browser. in example of pl/sql code 1
- number of such variable (as f01
in example of html code above). need choose number, not busy on page.
Comments
Post a Comment