" code statement in the body."/> " code statement in the body.">

Home >Web Front-end >HTML Tutorial >How to set textarea in html

How to set textarea in html

藏色散人
藏色散人Original
2021-05-12 15:00:195641browse

htmlHow to set textarea: First create an HTML sample file; then enter the "" code statement in the body .

How to set textarea in html

The operating environment of this article: Windows7 system, HTML5&&CSS3 version, Dell G3 computer.

The text area can hold an unlimited amount of text, and the default font for the text is a fixed-width font (usually Courier).

You can specify the size of the textarea through the cols and rows attributes, but a better way is to use the CSS height and width attributes.

Example

An HTML text area:

<!DOCTYPE html>
<html>
<head> 
<meta charset="utf-8"> 
<title></title> 
</head>
<body>

<textarea rows="10" cols="30">
我是一个文本框。
</textarea>

</body>
</html>

Effect:

How to set textarea in html

Recommended learning: "HTML video tutorial"

The above is the detailed content of How to set textarea in html. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn