Esempio n. 1
0
function set_game_info_selects()
{
    global $smarty;
    global $MONTH_SELECTED;
    global $DAY_SELECTED;
    global $YEAR_SELECTED;
    global $HOUR_SELECTED;
    global $MINUTE_SELECTED;
    global $AMPM_SELECTED;
    $smarty->assign('monthSelect', select_month('1'));
    $smarty->assign('daySelect', select_day('1'));
    $smarty->assign('yearSelect', select_year('1'));
    $smarty->assign('hourSelect', select_hour('1'));
    $smarty->assign('minuteSelect', select_minute('1'));
    $smarty->assign('ampmSelect', select_ampm('1'));
}
Esempio n. 2
0
function select_time($name, $time)
{
    if ($time == null) {
        $time = date('H:i');
    }
    $times = explode(':', $time);
    $hour = $times[0];
    $min = $times[1];
    return select_hour($name, '1', $hour) . select_min($name, '2', $min);
}
    public function testSelectHour()
    {
        $expect = <<<EOT
        <select name="date[hour]">
        <option value="00">00</option>
        <option value="01" selected="selected">01</option><option value="02">02</option>
        <option value="03">03</option><option value="04">04</option>
        <option value="05">05</option><option value="06">06</option>
        <option value="07">07</option><option value="08">08</option>
        <option value="09">09</option><option value="10">10</option>
        <option value="11">11</option><option value="12">12</option>
        <option value="13">13</option><option value="14">14</option>
        <option value="15">15</option><option value="16">16</option>
        <option value="17">17</option><option value="18">18</option>
        <option value="19">19</option><option value="20">20</option>
        <option value="21">21</option><option value="22">22</option>
        <option value="23">23</option>
        </select>
EOT;
        $this->assertDomEqual($expect, select_hour(new SDateTime(2006, 3, 31, 1, 29, 35)));
        $this->assertDomEqual($expect, select_hour(1));
    }
Esempio n. 4
0
select_hour();
?>
</select> 
			<select name="smin"><?php 
select_min();
?>
</select><br>
			 ~ <br>
			<span>到着  地点:</span>
			<select name="fi_loc"><?php 
select_place();
?>
</select>
			<span> 時刻:</span>
			<select name="fhur"><?php 
select_hour();
?>
</select>
			<select name="fmin"><?php 
select_min();
?>
</select>
		</label>
		<label><p>メモ:</p><textarea type="text" name="r_memo" id="form_ta" cols="60" rows="5" /></textarea></label>

	
	<!--	category:<br> -->

		</label>
		<input type="submit" class="btn_regi" value="登録する"/>
	</div>