Blogger Information
Blog 14
fans 0
comment 0
visits 27756
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
html 页面提供时间选择
花式BUG_beisi
Original
1346 people have browsed it

<dl>

        <dt >日期:</dt>

        <dd>

          <input type="text" class="text w150" maxlength="30" name="date" id="adddate" maxlength="50" value="<?php echo  $output['tv_info']['date'] ? date('Y-m-d',strtotime($output['tv_info']['date'])) :date('Y-m-d') ; ?>" />

        </dd>

      </dl>

      <dl>

        <dt>开始时间:</dt>

        <dd>

          <?php   list($start_time_h,$start_time_m) = explode(':', $output['tv_info']['start_time']); ?>

            <select name="start_time_h" style="">

              <?php for($i=0;$i<=23;$i++){ ?>

               <option   <?php if(intval($start_time_h)==$i){echo 'selected="selected"';} ?>  value="<?php echo $i;?>"><?php echo $i<10 ? '0'.$i : $i;?></option>

               <?php } ?>

            </select>时

            <select  name="start_time_m" style="">

              <?php for($i=0;$i<=59;$i++){ ?>

              <option   <?php if(intval($start_time_m)==$i){echo 'selected="selected"';} ?>  value="<?php echo $i;?>"><?php echo $i<10 ? '0'.$i : $i;?></option>

              <?php } ?>

           </select>分

        </dd>

      </dl>

      <dl>

        <dt>结束时间:</dt>

        <dd>

         <?php   list($end_time_h,$end_time_m) = explode(':', $output['tv_info']['end_time']); ?>

          <select name="end_time_h" style="">

            <?php for($i=0;$i<=23;$i++){ ?>

             <option   <?php if(intval($end_time_h)==$i){echo 'selected="selected"';} ?>  value="<?php echo $i;?>"><?php echo $i<10 ? '0'.$i : $i;?></option>

             <?php } ?>

          </select>时

          <select  name="end_time_m" style="">

            <?php for($i=0;$i<=59;$i++){ ?>

            <option   <?php if(intval($end_time_m)==$i){echo 'selected="selected"';} ?>  value="<?php echo $i;?>"><?php echo $i<10 ? '0'.$i : $i;?></option>

            <?php } ?>

         </select>分

        </dd>

      </dl>


Statement of this Website
The copyright of this blog article belongs to the blogger. Please specify the address when reprinting! If there is any infringement or violation of the law, please contact admin@php.cn Report processing!
All comments Speak rationally on civilized internet, please comply with News Comment Service Agreement
0 comments
Author's latest blog post