mirror of
https://github.com/jlengrand/LAFF.git
synced 2026-03-10 08:31:21 +00:00
19 lines
392 B
JavaScript
Executable File
19 lines
392 B
JavaScript
Executable File
function GenChoices( Name, CurChoice, nchoices, Choices ){
|
|
var i;
|
|
|
|
str = "";
|
|
|
|
str += "<select name=\""+Name+"\" id=\""+Name+"\" > \n\n";
|
|
|
|
for ( i=0; i<nchoices; i++ ){
|
|
str += " <option value="+i+"\n";
|
|
if ( parseInt(CurChoice) == i ) str += "selected";
|
|
str += "> "+Choices[ i ] + " </option>";
|
|
str += " \n\n";
|
|
}
|
|
|
|
str += "</select>";
|
|
|
|
return str;
|
|
}
|