当前位置: 首页>>代码示例>>PHP>>正文


PHP html::input方法代码示例

本文整理汇总了PHP中html::input方法的典型用法代码示例。如果您正苦于以下问题:PHP html::input方法的具体用法?PHP html::input怎么用?PHP html::input使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在html的用法示例。


在下文中一共展示了html::input方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: render

 /**
  * Render
  *
  * @param object $object
  * @return string
  */
 public static function render($object)
 {
     $input = $object->options['input'];
     $filter = $object->filter;
     $full_text_search = $filter['full_text_search'] ?? null;
     unset($filter['full_text_search']);
     // generating form
     $table = ['header' => ['name' => i18n(null, 'Column'), 'value' => i18n(null, 'Value'), 'sep' => ' ', 'value2' => ' '], 'options' => []];
     // fields
     foreach ($filter as $k => $v) {
         if (!empty($v['range'])) {
             $table['options'][$k] = ['name' => ['value' => i18n(null, $v['name']) . ':', 'width' => '25%', 'class' => 'list_filter_name'], 'value' => ['value' => self::render_column($v, $k, false, $input), 'width' => '30%'], 'sep' => ['value' => '—', 'width' => '1%', 'class' => 'list_filter_value'], 'value2' => ['value' => self::render_column($v, $k, true, $input), 'width' => '30%']];
         } else {
             $table['options'][$k] = ['name' => ['value' => i18n(null, $v['name']) . ':', 'width' => '25%', 'class' => 'list_filter_name'], 'value' => ['value' => self::render_column($v, $k, false, $input), 'width' => '30%']];
         }
     }
     // full text search last
     if (!empty($full_text_search)) {
         $names = [];
         foreach ($full_text_search as $v) {
             $names[] = i18n(null, $filter[$v]['name']);
         }
         $table['options']['full_text_search'] = ['name' => ['value' => i18n(null, 'Text Search') . ':', 'class' => 'list_filter_name'], 'value' => ['value' => html::input(['name' => 'filter[full_text_search]', 'class' => 'list_filter_full_text_search', 'size' => 15, 'value' => $input['filter']['full_text_search'] ?? null])], 'value2' => ['value' => implode(', ', $names), 'class' => 'list_filter_value']];
     }
     $body = html::table($table);
     $footer = html::button2(['name' => 'submit_filter', 'value' => i18n(null, 'Submit'), 'type' => 'primary', 'onclick' => "numbers.modal.hide('list_{$object->list_link}_filter'); \$('#list_{$object->list_link}_form').attr('target', '_self'); \$('#list_{$object->list_link}_form').attr('no_ajax', ''); return true;"]);
     return html::modal(['id' => "list_{$object->list_link}_filter", 'class' => 'large', 'title' => i18n(null, 'Filter'), 'body' => $body, 'footer' => $footer]);
 }
开发者ID:volodymyr-volynets,项目名称:frontend,代码行数:34,代码来源:filter.php

示例2: sign_up_sign_in

 public static function sign_up_sign_in($url)
 {
     // TODO: add sign in as guest.
     $dropdown_content = array('class' => 'dropdown-menu', 'style' => 'padding: 15px; padding-bottom: 0px;');
     $form = array('method' => 'post', 'action' => $url, 'accept-charset' => 'UTF-8');
     $username = array('type' => 'text', 'placeholder' => 'Username', 'id' => 'username', 'name' => 'username');
     $password = array('type' => 'password', 'placeholder' => 'Password', 'id' => 'password', 'name' => 'password');
     $submit = array('value' => 'Sign In', 'class' => 'btn btn-primary btn-block', 'id' => 'sign-in');
     return html::ul('nav pull-right', html::li(html::a(new moodle_url('/login/signup.php'), 'Sign Up')) . bootstrap::list_divider() . bootstrap::dropdown('Sign In', html::div($dropdown_content, html::form($form, html::input($username) . html::input($password) . html::checkbox('rememberusername', 'Remember username') . html::submit($submit)))));
 }
开发者ID:rbclark,项目名称:moodle-theme_bootstrap_renderers,代码行数:10,代码来源:bootsnipp.php

示例3: inline_search_append

 public static function inline_search_append($action, $placeholder, $value, $submit_text)
 {
     $form_attributes['class'] = 'inline-form';
     $form_attributes['method'] = 'get';
     $form_attributes['action'] = $action;
     $input_attributes['type'] = 'text';
     $input_attributes['name'] = 'query';
     $input_attributes['placeholder'] = $placeholder;
     $input_attributes['value'] = $value;
     return html::form($form_attributes, html::div('input-append', html::input($input_attributes) . html::submit(array('value' => $submit_text))));
 }
开发者ID:rbclark,项目名称:moodle-theme_bootstrap_renderers,代码行数:11,代码来源:form.php

示例4: calendar

 /**
  * see html::calendar()
  */
 public static function calendar($options = [])
 {
     // include js & css files
     if (empty($options['readonly'])) {
         layout::add_js('/numbers/media_submodules/numbers_frontend_components_calendar_numbers_media_js_base.js');
         layout::add_css('/numbers/media_submodules/numbers_frontend_components_calendar_numbers_media_css_base.css');
     }
     // font awesome icons
     library::add('fontawesome');
     // widget parameters
     $type = $options['calendar_type'] ?? $options['type'] ?? 'date';
     $widget_options = ['id' => $options['id'], 'type' => $type, 'format' => $options['calendar_format'] ?? format::get_date_format($type), 'date_week_start_day' => $options['calendar_date_week_start_day'] ?? 1, 'date_disable_week_days' => $options['calendar_date_disable_week_days'] ?? null, 'master_id' => $options['calendar_master_id'] ?? null, 'slave_id' => $options['calendar_slave_id'] ?? null];
     $options['type'] = 'text';
     // determine input size
     $placeholder = format::get_date_placeholder($widget_options['format']);
     $options['size'] = strlen($placeholder);
     // set placeholder
     if (!empty($options['placeholder']) && $options['placeholder'] == 'format::get_date_placeholder') {
         $options['placeholder'] = $placeholder;
         $options['title'] = ($options['title'] ?? '') . ' (' . $placeholder . ')';
     }
     if (isset($options['calendar_icon']) && ($options['calendar_icon'] == 'left' || $options['calendar_icon'] == 'right')) {
         $position = $options['calendar_icon'];
         if (i18n::rtl()) {
             if ($position == 'left') {
                 $position = 'right';
             } else {
                 $position = 'left';
             }
         }
         $icon_type = $type == 'time' ? 'clock-o' : 'calendar';
         unset($options['calendar_icon']);
         if (empty($options['readonly'])) {
             $icon_onclick = 'numbers_calendar_var_' . $options['id'] . '.show();';
         } else {
             $icon_onclick = null;
         }
         $icon_value = html::span(['onclick' => $icon_onclick, 'class' => 'numbers_calendar_icon numbers_prevent_selection', 'value' => html::icon(['type' => $icon_type])]);
         $result = html::input_group(['value' => html::input($options), $position => $icon_value, 'dir' => 'ltr']);
         $div_id = $options['id'] . '_div_holder';
         $result .= html::div(['id' => $div_id, 'class' => 'numbers_calendar_div_holder']);
         $widget_options['holder_div_id'] = $div_id;
     } else {
         $result = html::input($options);
     }
     // we do not render a widget if readonly
     if (empty($options['readonly'])) {
         layout::onload('numbers_calendar(' . json_encode($widget_options) . ');');
     }
     return $result;
 }
开发者ID:volodymyr-volynets,项目名称:frontend,代码行数:54,代码来源:base.php

示例5: captcha

 /**
  * Captcha
  *
  * @param array $options
  * @return string
  */
 public static function captcha($options = [])
 {
     $captcha_link = $options['id'] ?? 'default';
     // validation
     if (!empty($options['validate'])) {
         return self::validate($captcha_link, $options['password']);
     }
     // generating password
     $password = self::generate_password($captcha_link, $options['password_letters'] ?? null, $options['password_length'] ?? 5);
     array_key_unset($options, ['password_letters', 'password_length']);
     $image_options = ['src' => 'data:image/png;base64,' . base64_encode(self::draw($password, ['return_image' => true])), 'style' => $options['img_style'] ?? 'vertical-align: middle;'];
     if (!empty($options['only_image'])) {
         return html::img($image_options);
     } else {
         return '<table width="100%"><tr><td>' . html::input($options) . '</td><td width="1%">&nbsp;</td><td width="1%">' . html::img($image_options) . '</td></tr></table>';
     }
 }
开发者ID:volodymyr-volynets,项目名称:frontend,代码行数:23,代码来源:base.php

示例6: createManageLink

 private function createManageLink($module, $type = 'info')
 {
     static $users;
     if (empty($users)) {
         $users = $this->loadModel('user')->getPairs('noletter');
     }
     $linkHtml = $module->name;
     if (common::hasPriv('info', 'TreeEdit')) {
         $linkHtml .= ' ' . html::a(helper::createLink('info', 'TreeEdit', "module={$module->id}"), $this->lang->tree->edit, '', 'class="iframe"');
     }
     if (common::hasPriv('info', 'TreeManage')) {
         $linkHtml .= ' ' . html::a(helper::createLink('info', 'TreeManage', "root={$module->root}&module={$module->id}&type={$type}"), $this->lang->tree->child);
     }
     if (common::hasPriv('info', 'TreeDelete')) {
         $linkHtml .= ' ' . html::a(helper::createLink('info', 'TreeDelete', "root={$module->root}&module={$module->id}"), $this->lang->delete, 'hiddenwin');
     }
     if (common::hasPriv('info', 'TreeUpdateOrder')) {
         $linkHtml .= ' ' . html::input("orders[{$module->id}]", $module->order, 'style="width:30px;text-align:center"');
     }
     return $linkHtml;
 }
开发者ID:huokedu,项目名称:zentao,代码行数:21,代码来源:model.php

示例7:

          <td colspan='2'><?php 
echo html::submitButton();
?>
</td>
        </tr>
      </table>
    </form>

    <div class='hide row-custom'>
      <div class='row form-group'>
        <div class="col-xs-3"> <?php 
echo html::input('label[key]', '', "class='form-control' placeholder='{$lang->product->placeholder->label}'");
?>
</div>
        <div class="col-xs-8"> <?php 
echo html::input('value[key]', '', "class='form-control' placeholder='{$lang->product->placeholder->value}'");
?>
</div>
        <div class="col-xs-1">
          <?php 
echo html::a('javascript:;', "<i class='icon-plus'></i>", "class='btn btn-link pull-left btn-mini btn-add'");
?>
          <?php 
echo html::a('javascript:;', "<i class='icon-remove'></i>", "class='btn btn-link pull-left btn-mini btn-remove'");
?>
        </div>
      </div>
    </div>

  </div>
</div>
开发者ID:mustafakarali,项目名称:b2c-1,代码行数:31,代码来源:edit.html.php

示例8:

?>
            <?php 
echo html::hidden('mode', 'fixed');
?>
            <?php 
echo html::hidden('orderBy', 'pv_desc');
?>
            <table class='table table-borderless'>
              <tr>
                <td style='padding:4px'>
                  <?php 
echo html::input('begin', $this->get->begin, "placeholder='{$lang->stat->begin}' class='form-date w-120px'");
?>
 
                  <?php 
echo html::input('end', $this->get->end, "placeholder='{$lang->stat->end}' class='form-date w-120px'");
?>
                  <?php 
echo html::submitButton($lang->stat->view, "btn btn-xs btn-info");
?>
                </td>
              </tr>
            </table>
          </form>
        </li>
       </ul>
    </div>
  </div>
  <table class='table table-hover table-bordered table-striped tablesorter'>
    <thead>
      <tr class='text-center'>
开发者ID:jnan77,项目名称:chanzhieps,代码行数:31,代码来源:page.html.php

示例9:

    die;
}
include "header.html.php";
?>
<form method='post' action='<?php 
echo helper::createLink('ui', 'setlogo');
?>
' class='ve-form mw-800px center-block' enctype='multipart/form-data'>
  <table class='table table-form'>
    <tr>
      <th><?php 
echo $lang->site->name;
?>
</th>
      <td><?php 
echo html::input('name', $this->config->site->name, "class='form-control'");
?>
</td><td></td>
    </tr>
    <tr>
      <th>
        <?php 
echo $lang->ui->logo;
?>
      </th>
      <td><?php 
echo html::file('files', "class='form-control'");
?>
</td>
      <td><?php 
echo html::select('theme', $lang->ui->logoList, '', "class='form-control'");
开发者ID:hansen1416,项目名称:eastsoft,代码行数:31,代码来源:editlogo.html.php

示例10:

    echo "<input type='button' tabindex='-1' class='addbutton btn btn-xs' onclick='postInsert({$stepID})' value='{$lang->testcase->insertAfter}'  />";
    echo "<input type='button' tabindex='-1' class='delbutton btn btn-xs' onclick='deleteRow({$stepID})'  value='{$lang->testcase->deleteStep}'   />";
    echo "</div></td>";
    echo '</tr>';
}
?>
          </table>
        </td> 
      </tr>
      <tr>
        <th><?php 
echo $lang->testcase->keywords;
?>
</th>
        <td colspan='3'><?php 
echo html::input('keywords', $keywords, "class='form-control'");
?>
</td>
      </tr>  
       <tr>
        <th><?php 
echo $lang->testcase->files;
?>
</th>
        <td colspan='3'><?php 
echo $this->fetch('file', 'buildform');
?>
</td>
      </tr>  
      <tr>
        <td colspan='4' class='text-center'><?php 
开发者ID:XMGmen,项目名称:zentao,代码行数:31,代码来源:create.html.php

示例11:

}
echo "<div class='form-group'><div class='col-xs-8 col-md-offset-2'>" . html::submitButton() . "</div></div>";
echo html::hidden('parent', $parent);
?>
      
    </div>
  </div>
</form>
<div class='child hide'>
  <div class='form-group category'>
    <div class='col-xs-6 col-md-4 col-md-offset-2'><?php 
echo html::input("children[]", '', "class='form-control' placeholder='{$this->lang->category->name}'");
?>
</div>
    <div class='col-xs-6 col-md-4'><?php 
echo html::input("alias[]", '', "class='form-control' placeholder='{$this->lang->category->alias}'");
?>
</div>
    <div class='col-xs-6 col-md-2'>
      <?php 
echo "<i class='icon-move sort-handle'> </i>";
?>
      <?php 
echo html::a('javascript:;', "<i class='icon-plus'></i>", "class='btn btn-link pull-left btn-mini btn-plus'");
?>
      <?php 
echo html::a('javascript:;', "<i class='icon-remove'></i>", "class='btn btn-link pull-left btn-mini btn-remove'");
?>
    </div>
    <?php 
echo html::hidden('mode[]', 'new');
开发者ID:jnan77,项目名称:chanzhieps,代码行数:31,代码来源:children.html.php

示例12:

    <small class='text-muted'> <?php 
echo html::icon($lang->icons['copy']);
?>
</small>
  </div>
</div>

<form class='form-condensed mw-500px pdb-20' method='post' target='hiddenwin'>
  <table align='center' class='table table-form'> 
    <tr>
      <th class='w-100px'><?php 
echo $lang->group->name;
?>
</th>
      <td><?php 
echo html::input('name', $group->name, "class='form-control'");
?>
</td>
    </tr>
    <tr>
      <th><?php 
echo $lang->group->desc;
?>
</th>
      <td><?php 
echo html::textarea('desc', $group->desc, "rows='5' class='form-control'");
?>
</td>
    </tr>
    <tr>
      <th><?php 
开发者ID:leowh,项目名称:colla,代码行数:31,代码来源:copy.html.php

示例13:

      <td class='text-left' style='overflow:visible'><?php 
echo html::select("plan[%s]", $plans, $planID, "class='form-control'");
?>
</td>
      <td><?php 
echo html::input("title[%s]", $storyTitle, "class='form-control'");
?>
</td>
      <td>
        <?php 
echo html::textarea("spec[%s]", $spec, "rows='1' class='form-control'");
?>
      </td>
      <td><?php 
echo html::select("pri[%s]", (array) $lang->story->priList, $pri, 'class=form-control');
?>
</td>
      <td><?php 
echo html::input("estimate[%s]", $estimate, "class='form-control'");
?>
</td>
      <td><?php 
echo html::select("needReview[%s]", $lang->story->reviewList, 0, "class='form-control'");
?>
</td>
    </tr>
  </tbody>
</table>
<?php 
include '../../common/view/pastetext.html.php';
include '../../common/view/footer.html.php';
开发者ID:iamazhi,项目名称:zentaopms,代码行数:31,代码来源:batchcreate.html.php

示例14: isset

            <div class='row'>
              <?php 
$placeholder = $this->app->getClientLang() == 'en' ? "placeholder='{$lang->site->policeTip}'" : '';
?>
              <div class='col-sm-4'><?php 
echo html::input('policeSN', isset($this->config->site->policeSN) ? $this->config->site->policeSN : '', "class='form-control col-xs-2' {$placeholder}");
?>
</div>
              <div class='col-sm-8'>
                <div class='input-group'>
                  <span class="input-group-addon"><?php 
echo $lang->site->policeLink;
?>
</span>
                  <?php 
echo html::input('policeLink', isset($this->config->site->policeLink) ? $this->config->site->policeLink : 'http://www.miitbeian.gov.cn', "class='form-control'");
?>
                </div>
              </div>
            </div>
          </td>
        </tr>
        <tr>
          <th></th>
          <td colspan='2'><?php 
echo html::submitButton();
?>
</td>
        </tr>
      </table>
    </form>
开发者ID:easysoft,项目名称:chanzhi_extension,代码行数:31,代码来源:setbasic.html.php

示例15:

        <?php 
        echo html::input("duplicateStoryIDList[{$story->id}]", '', "class=w-30px placeholder='{$lang->idAB}'");
        ?>
        </div>

        <div class='f-left' id='<?php 
        echo 'childStoryBox' . $story->id;
        ?>
' <?php 
        if ($story->closedReason != 'subdivided') {
            echo "style='display:none'";
        }
        ?>
>
        <?php 
        echo html::input("childStoriesIDList[{$story->id}]", '', "class=w-30px placeholder='{$lang->idAB}'");
        ?>
        </div>
      </td>
      <?php 
    } else {
        ?>
  
      <td class='f-left'><?php 
        echo html::select("closedReasons[{$story->id}]", $lang->story->reasonList, $story->closedReason, 'class="w-60px" disabled="disabled"');
        ?>
</td>
      <?php 
    }
    ?>
开发者ID:huokedu,项目名称:zentao,代码行数:30,代码来源:batchclose.html.php


注:本文中的html::input方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。