【问题标题】:What is the alternative of select tag in HTML5 with using NodeJS?使用 NodeJS 在 HTML5 中选择标签的替代方法是什么?
【发布时间】:2020-07-10 23:04:55
【问题描述】:

如果我在 html5 中使用 <select> 标记并使用 NodeJS,我会遇到错误,例如 Error [ERR_HTTP_HEADERS_SENT]: Cannot set headers after they are sent to the client

所以,我想要<select 标签的替代代码

【问题讨论】:

  • 在 HTML 中使用 <select> 元素不会导致该错误。 HTML 5 不会用其他任何东西替换 <select>
  • 如果我从代码中删除了
  • 然后,您与代码的其他部分发生了一些奇怪的交互,您需要修复这种交互。
  • 请提供一个minimal reproducible example,显示包含select 元素并产生您所看到的错误的最少代码量。

标签: html css select html5-canvas option


【解决方案1】:
**<div class="form-group col-md-3">
                                <label>Designation</label>
                                <div class="col-xs-8">
                                    <div class="col-xs-8">
                                        <select class="form-control" name="faculty">
                                            <option>1</option>
                                            <option>2</option>
                                            <option>3</option>
                                            <option>4</option>
                                            <option>5</option>
                                        </select>
                                    </div>
                                </div>
                            </div>**

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2013-05-08
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2023-04-11
    • 1970-01-01
    相关资源
    最近更新 更多