| @@ 2484-2492 (lines=9) @@ | ||
| 2481 | * Draws an HTML form select with the given options |
|
| 2482 | * |
|
| 2483 | */ |
|
| 2484 | public function make_select($name,$values,$checked='') |
|
| 2485 | { |
|
| 2486 | $output = '<select name="'.$name.'" id="'.$name.'">'; |
|
| 2487 | foreach($values as $key => $value) { |
|
| 2488 | $output .= '<option value="'.$key.'" '.(($checked==$key)?'selected="selected"':'').'>'.$value.'</option>'; |
|
| 2489 | } |
|
| 2490 | $output .= '</select>'; |
|
| 2491 | return $output; |
|
| 2492 | } |
|
| 2493 | ||
| 2494 | /** |
|
| 2495 | * Translates a form date into a more usable format |
|
| @@ 2414-2422 (lines=9) @@ | ||
| 2411 | * @param string $checked |
|
| 2412 | * @return string |
|
| 2413 | */ |
|
| 2414 | function make_select($name, $values, $checked = '') |
|
| 2415 | { |
|
| 2416 | $output = '<select name="'.$name.'" id="'.$name.'">'; |
|
| 2417 | foreach ($values as $key => $value) { |
|
| 2418 | $output .= '<option value="'.$key.'" '.(($checked==$key) ? 'selected="selected"' : '').'>'.$value.'</option>'; |
|
| 2419 | } |
|
| 2420 | $output .= '</select>'; |
|
| 2421 | return $output; |
|
| 2422 | } |
|
| 2423 | ||
| 2424 | /** |
|
| 2425 | * @param $name |
|