html - 在 HTML 中调整输入框文本区域的大小
问题描述
我是 HTML 新手,我正在尝试调整输入框的大小。这是我的代码
<!DOCTYPE html>
<html>
<body>
<h1> Text Summarizer </h1>
<div class="login">
<h1>Insert the text that you want to summarize in the box below</h1>
<form action="{{url_for('summary')}}"method="post">
<input type="text" name="input" placeholder="type here" required="required">
<br><br>
<input type="submit",value="summary">
</form>
<br>
<br>
{{data}}
</div>
这是我尝试过的。
<!DOCTYPE html>
<html>
<body>
<h1> Text Summarizer </h1>
<div class="login">
<h1>Insert the text that you want to summarize in the box below</h1>
<form action="{{url_for('summary')}}"method="post">
<input type="text" name="input" placeholder="type here" required="required">
<br><br>
<textarea rows= "4" cols="50">
</textarea>
<br><br>
<input type="submit",value="summary">
</form>
<br>
<br>
{{data}}
</div>
我现在在原始文本框旁边得到了第二个框。任何帮助都感激不尽。
解决方案
如果您希望它是一个带有“在此处输入”占位符的大文本字段,请执行以下操作:
<!DOCTYPE html>
<html>
<body>
<h1> Text Summarizer </h1>
<div class="login">
<h1>Insert the text that you want to summarize in the box below</h1>
<form action="{{url_for('summary')}}"method="post">
<textarea rows= "4" cols="50" type="text" name="input" placeholder="type here" required="required">
</textarea>
<br><br>
<input type="submit" value="summary">
</form>
<br>
<br>
{{data}}
</div>
推荐阅读
- java - 读取 Json 文件但键没有引号
- java - 如果相同,则将数组中的值相乘
- python - 有没有办法在 Python 上使用 itertools 获得不重叠且详尽的列表的“组合组”?
- angular - 在Angular中动态使用setValidators后如何不丢失初始化的验证器?
- python - Gimp python-fu 如何更改菜单文本(标签)
- linux - 为什么 `ld -L -l...` 不匹配 `ld /path/to/library.so` 的行为?
- javascript - 找不到 gm/convert 二进制文件 Node.js pdf-to-image 转换
- javascript - 使用 Google Drive API Node js 上传文件时,文件名是“无标题”
- go - 如何使用 k8s.io client-go rest API 请求传递容器名称
- java - 如何使用背景/异步任务制作线性/更具可读性的 Java 代码