Beispiel #1
0
Datei: add.php Projekt: mmr/b1n
                        </td>
                    </tr>
                    <tr>
                        <td class='formitem' width='1'>*</td>
                        <td class='formitem'>File</td>
                        <td class='forminput'>
                            <input type='file' name='file' onChange='b1n_tryToIdentify(this);' />
                        </td>
                    </tr>
                    <tr>
                        <td class='formitem' width='1'>&nbsp;</td>
                        <td class='formitem'>Type</td>
                        <td class='forminput'>
<?php 
$options = array("Image" => "I", "PDF" => "P", "Misc" => "M");
echo b1n_buildSelect($options, $reg_data['fil_type'], array('name' => 'fil_type'));
?>
                        </td>

                    </tr>
                    <tr>
                        <td class='formitem' width='1'>&nbsp;</td>
                        <td class='formitem'>Desc</td>
                        <td class='forminput'>
                            <textarea name="fil_desc" rows="<?php 
echo b1n_DEFAULT_ROWS;
?>
" cols="<?php 
echo b1n_DEFAULT_COLS;
?>
" wrap="<?php 
Beispiel #2
0
function b1n_buildSelectFromHour($name, $array_hour = array(), $extra_params = array(), $max_hour = 24, $min_inc = 1, $hour_inc = 1)
{
    if (sizeof($array_hour) < 2) {
        $array_hour['hour'] = 0;
        $array_hour['min'] = 0;
    }
    // Hour
    $params = array("name" => $name . "[hour]");
    $hash = array();
    for ($i = 0; $i < $max_hour; $i += $hour_inc) {
        $i = sprintf("%02d", $i);
        $hash[$i] = $i;
    }
    $ret = b1n_buildSelect($hash, $array_hour['hour'], $params + $extra_params);
    // Minute
    $params = array("name" => $name . "[min]");
    $hash = array();
    for ($i = 0; $i <= 59; $i += $min_inc) {
        $i = sprintf("%02d", $i);
        $hash[$i] = $i;
    }
    $ret .= ":" . b1n_buildSelect($hash, $array_hour['min'], $params + $extra_params);
    return $ret;
}
Beispiel #3
0
?>
                            <input type='radio' name='search_order_type' value='ASC' class='noborder' <?php 
echo $search["search"]["search_order_type"] != 'DESC' ? "checked" : "";
?>
 /> Asc
                            <input type='radio' name='search_order_type' value='DESC' class='noborder' <?php 
echo $search["search"]["search_order_type"] == 'DESC' ? "checked" : "";
?>
 /> Desc
                        </td>
                    </tr>
                    <tr>
                        <td class='formitem'>Quantity</td>
                        <td class='forminput'>
                            <?php 
echo b1n_buildSelect($search["possible_quantities"], array($search["search"]["search_quantity"]), array("name" => "search_quantity"));
?>
                        </td>
                    </tr>
                    <tr>
                        <td class='formitem'>Search</td>
                        <td class='forminput'>
                            <input type='text' name='search_text' value="<?php 
echo b1n_inHtml($search["search"]["search_text"]);
?>
" size="<?php 
echo b1n_DEFAULT_SIZE;
?>
" maxlength="<?php 
echo b1n_DEFAULT_MAXLEN;
?>
Beispiel #4
0
                case "date":
                case "date_check_exp":
                case "date_check_dob":
                    echo b1n_buildSelectFromDate($reg['reg_data'], $reg_data[$reg['reg_data']], $reg['extra']['year_start'], $reg['extra']['year_end'], $reg['extra']['params']);
                    break;
                case "date_hour":
                    echo b1n_buildSelectFromDateHour($reg['reg_data'], $reg_data[$reg['reg_data']], $reg['extra']['year_start'], $reg['extra']['year_end'], $reg['extra']['params']);
                    break;
                case "fk":
                    if (!isset($reg['extra']['where'])) {
                        $reg['extra']['where'] = array();
                    }
                    echo b1n_buildSelectCommon($sql, $reg['extra']['name'], $reg['extra']['value'], $reg['extra']['text'], $reg['extra']['table'], $reg_data[$reg['reg_data']], $reg['extra']['params'], $reg['extra']['where']);
                    break;
                case "defined":
                    echo b1n_buildSelect($reg['extra']['options'], $reg_data[$reg['reg_data']], $reg['extra']['params'] + array("name" => $reg['reg_data']));
                    break;
            }
            break;
        case "radio":
            foreach ($reg['extra']['options'] as $opt_title => $opt_value) {
                ?>
                            <input type="radio" name="<?php 
                echo $reg['reg_data'];
                ?>
" value="<?php 
                echo $opt_value;
                ?>
" class="noborder"<?php 
                if ($opt_value == $reg_data[$reg['reg_data']]) {
                    echo " checked";