Home > Web Front-end > HTML Tutorial > HTML 入门笔记 - 初识HTML_html/css_WEB-ITnose

HTML 入门笔记 - 初识HTML_html/css_WEB-ITnose

WBOY
Release: 2016-06-24 11:25:06
Original
7136 people have browsed it

本人在慕课网学习HTML+CSS基础课程,记录一些文字,方便自己回忆,也希望对大家有所帮助


基础框架

<!DOCTYPE HTML><html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"><title>标题标签</title></head><body>    <h1>了不起的盖茨比</h1>    <p>《了不起的盖茨比》为那个奢靡年代的缩影。盖茨比怀揣着对"美国梦"的期翼,投身到那个年代的灯红酒绿之中,却在名利场中看尽世态炎凉,以及浮华背后一切终将逝去的空虚怅惘。1925年《了不起的盖茨比》问世。    </p></body></html>
Copy after login

了解HTML的代码注释

什么是代码注释?代码注释的作用是帮助程序员标注代码的用途,过一段时间后再看你所编写的代码,就能很快想起这段代码的用途。代码注释不仅方便程序员自己回忆起以前代码的用途,还可以帮助其他程序员很快的读懂你的程序的功能,方便多人合作开发网页代码。

语法:

认识标签

文档的头部描述了文档的各种属性和信息,包括文档的标题等。绝大多数文档头部包含的数据都不会真正作为内容显示给读者。

<head>    <title>...</title>    <meta>    <link>    <style>...</style>    <script>...</script></head>
Copy after login
  1. 标签在<title> 和<title> 标签之间的文字内容是网页的标题信息,它会出现在浏览器的标题栏中。网页的title标签用于告诉用户和搜索引擎这个网页的主要内容是什么,搜索引擎可以通过网页标题,迅速的判断出网页的主题。每个网页的内容都是不同的,每个网页都应该有一个独一无二的title。例如:<div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="sycode" name="code"><head> <title>hello world</title></head></pre><div class="contentsignin">Copy after login</div></div><title>标签的内容“hello world”会在浏览器中的标题栏上显示出来,如下图所示 <p> <p></p> </p></li> </ol> <hr /> <h2><strong><body>标签,网页上显示的内容放在这里</strong></h2> <p>在网页上要展示出来的页面内容一定要放在body标签中。如下图是一个新闻文章的网页。</p> <p> <p></p> </p> <hr /> <h2><strong>开始学习<p>标签,添加段落</strong></h2> <p>如果想在网页上显示文章,这时就需要<p>标签了,把文章的段落放到<p>标签中。 </p> <p>语法: <p>段落文本</p> </p> <p>注意一段文字一个<p>标签,如在一篇新闻文章中有3段文字,就要把这3个段落分别放到3个<p>标签中。如下图所示。</p> <p> <p></p> </p> <hr /> <h2><strong>了解<hx(1-6)>标签,为你的网页添加标题</strong></h2> <p>文章的段落用<p>标签,那么文章的标题用什么标签呢?在本节我们将使用<hx>标签来制作文章的标题。标题标签一共有6个,h1、h2、h3、h4、h5、h6分别为一级标题、二级标题、三级标题、四级标题、五级标题、六级标题。并且依据重要性递减。<h1>是最高的等级。 </p> <p>语法:<hx>标题文本</hx> x:1-6</p> <p>注意:因为h1标签在网页中比较重要,所以一般h1标签被用在网站名称上。腾讯网站就是这样做的。如:<h1>腾讯网</h1> </p> <p>h1-h6标签的默认样式:标签代码:</p> <p> <p></p> </p> <p>在浏览器中显示的样式:</p> <p> <p></p> </p> <hr /> <h2><strong>加入强调语气,使用<strong>和<em>标签</strong></h2> <p>有了段落又有了标题,现在如果想在一段话中特别强调某几个文字,这时候就可以用到<em>或<strong>标签但两者在强调的语气上有区别: </p> <ul> <li><em> 表示强调,在浏览器中<em> 默认用斜体表示</li> <li><strong>表示更强烈的强调,在浏览器中<strong>用粗体表示。</li> <li>两个标签相比,目前国内前端程序员更喜欢使用<strong>表示强调。</li> </ul> <p>在浏览器中默认样式是有区别的:</p> <p> <p></p> </p> <p>浏览器中的样子,如下图。</p> <p> <p></p> </p> <p>语法:<em>需要强调的文本</em><strong>需要强调的文本</strong></p> <p>栗子:在网上商城中,某产品的打折后的价格是需要强调的。如下图。</p> <p> <p></p> </p> <p>代码实现:</p> <p> <p></p> </p> <hr /> <h2><strong>使用<span>标签为文字设置单独样式</strong></h2> <p>语法:<span>文本</span></p> <p>我们对<em>、<strong>、<span>这三个标签进行一下总结:</p> <ol> <li><p><em>和<strong>标签是为了强调一段话中的关键字时使用,它们的语义是强调。</p></li> <li><p><span>标签是没有语义的,它的作用就是为了设置单独的样式用的。</p></li> </ol> <p>如果现在我们想把上一小节的第一段话“美国梦”三个字设置成blue(蓝色),但注意不是为了强调“美国梦”,而只是想为它设置和其它文字不同的样式(并不想让屏幕阅读器对“美国梦”这三个字加重音读出),所以这样情况下就可以用到<span>标签了。如下面例子:</p> <div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="sycode" name="code"><p>1922年的春天,一个想要成名名叫<em>尼克•卡拉威</em>(托比•马奎尔Tobey Maguire 饰)的作家,离开了美国中西部,来到了纽约。那是一个道德感渐失,爵士乐流行,走私为王,<strong>股票</strong>飞涨的时代。为了追寻他的<span>美国梦</span>,他搬入纽约附近一海湾居住。</p></pre><div class="contentsignin">Copy after login</div></div> <p>我们如果想设置“美国梦”三个字设置成blue(蓝色),只需要在<style>标签中加入:</p> <div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="sycode" name="code">span{ color:blue;}</pre><div class="contentsignin">Copy after login</div></div> <p>css部分,以后会聊,你能大概明白span就是能干单独设置样式的活,就ok了 </p> <hr /> <h2><strong><q>标签,短文本引用</strong></h2> <p>想在你的html中加一段引用吗?比如在你的网页的文章里想引用某个作家的一句诗,这样会使你的文章更加出彩,那么<q>标签是你所需要的。</p> <p>语法:<q>引用文本</q></p> <p>栗子: </p> <div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="sycode" name="code"><p>最初知道庄子,是从一首诗<q>庄生晓梦迷蝴蝶。望帝春心托杜鹃。</q>开始的。虽然当时不知道是什么意思,只是觉得诗句挺特别。后来才明白这个典故出自是庄子的《逍遥游》,《逍遥游》代表了庄子思想的最高境界,是对世俗社会的功名利禄及自己的舍弃。</p></pre><div class="contentsignin">Copy after login</div></div> <p>讲解: </p> <ol> <li><p>在上面的例子中,“庄生晓梦迷蝴蝶。望帝春心托杜鹃。” 这是一句诗歌,出自晚唐诗人李商隐的《锦瑟》 。因为不是作者自己的文字,所以需要使用实现引用。</p></li> <li><p>注意要引用的文本不用加双引号,浏览器会对q标签自动添加双引号。</p></li> </ol> <p>下图是代码显示结果:</p> <p> <p></p> </p> <p>注意这里用标签的真正关键点不是它的默认样式双引号(如果这样我们不如自己在键盘上输入双引号就行了),而是它的语义:引用别人的话。</p> <hr /> <h2><strong><blockquote>标签,长文本引用</strong></h2> <p><blockquote>的作用也是引用别人的文本。但它是对长文本的引用,如在文章中引入大段某知名作家的文字,这时需要这个标签。等等,上一节<q>标签不是也是对文本的引用吗?不要忘记<q>标签是对简短文本的引用,比如说引用一句话就用到<q>标签。如想在我的文章中引用李白《关山月》中的诗句,因为引用文本比较长,所以使用<blockquote>。 </p> <p>语法:<blockquote>引用文本</blockquote>如下面例子:</p> <div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="sycode" name="code"><blockquote>明月出天山,苍茫云海间。长风几万里,吹度玉门关。汉下白登道,胡窥青海湾。由来征战地,不见有人还。 戍客望边色,思归多苦颜。高楼当此夜,叹息未应闲。</blockquote></pre><div class="contentsignin">Copy after login</div></div> <p>浏览器对<blockquote>标签的解析是缩进样式。如下图所示:</p> <p> <p></p> </p> <hr /> <h2><strong>使用<br>标签分行显示文本</strong></h2> <p>例子,我们想让一首诗显示得更美观些,如显示下面效果:</p> <p> <p></p> </p> <p>怎么可以让每一句诗词后面加入一个折行呢?那就可以用到<br />标签了,在需要加回车换行的地方加入<br />,<br />标签作用相当于word文档中的回车。代码改为: </p> <div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="sycode" name="code"><h2>《咏桂》</h2><p>暗淡轻黄体性柔,<br />情疏迹远只香留。<br />何须浅碧深红色,<br />自是花中第一流。</pre><div class="contentsignin">Copy after login</div></div> <p>诗文在浏览器中显示为:</p> <p> <p></p> </p> <hr /> <h2><strong>为你的网页中添加一些空格</strong></h2> <p>在html代码中输入空格、回车都是没有作用的。要想输入空格,必须写入。<strong>不要忘了那个分号</strong> </p> <p>在html代码中输入空格是不起作用的,如下代码。</p> <p> <p></p> </p> <p>在浏览中显示,还是没有空格效果。</p> <p> <p></p> </p> <p>输入空格的正确方法:</p> <p> <p></p> </p> <p>在浏览器中的显示出来的空格效果。如下图所示。</p> <p> <p></p> </p> <hr /> <h2><strong>认识<hr>标签,添加水平横线</strong></h2> <p>在信息展示时,有时会需要加一些用于分隔的横线,这样会使文章看起来整齐些。如下图所示:</p> <p> <p></p> </p> <p>语法:</p> <ul> <li>html4.01版本 <hr></li> <li>xhtml1.0版本 <hr />注意:</li> <li><hr />标签和<br />标签一样也是一个空标签,所以只有一个开始标签,没有结束标签。</li> <li><hr />标签的在浏览器中的默认样式线条比较粗,颜色为灰色,可能有些人觉得这种样式不美观,没有关系,这些外在样式在我们以后学习了css样式表之后,都可以对其修改。</li> <li>大家注意,现在一般使用 xhtml1.0 的版本(其它标签也是),这种版本比较规范。</li> </ul> <hr /> <h2><strong><address>标签,为网页加入地址信息</strong></h2> <p>一般网页中会有一些网站的联系地址信息需要在网页中展示出来,这些联系地址信息如公司的地址就可以<address>标签。也可以定义一个地址(比如电子邮件地址)、签名或者文档的作者身份。栗子: </p> <div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="sycode" name="code"><address>本文的作者:<a href="mailto:zhaoliangsyn@163.com">zhaolion</a></address></pre><div class="contentsignin">Copy after login</div></div> <hr /> <h2><strong>想加入一行代码吗?使用<code>标签</strong></h2> <p>在介绍语言技术的网站中,避免不了在网页中显示一些计算机专业的编程代码,当代码为一行代码时,你就可以使用<code>标签了,如下面例子: </p> <p><code>var i = a + b;</code> </p> <p>注意:在文章中一般如果要插入多行代码时不能使用<code>标签了。<strong>如果是多行代码,可以使用<div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="brush:php;toolbar:false">标签</strong>。</p> <hr /> <h2><strong>使用<pre class="brush:php;toolbar:false">标签为你的网页加入大段代码</strong></h2> <p>在上节中介绍加入一行代码的标签为<code>,但是在大多数情况下是需要加入大段代码的,如下图:</p> <p> <p></p> </p> <p>怎么办?不会是每一代码都加入一个<code>标签吧,没有这么复杂,这时候就可以使用<pre class="brush:php;toolbar:false">标签。 </p> <p>语法:<pre class="brush:php;toolbar:false">语言代码段</pre><div class="contentsignin">Copy after login</div></div></p> <p><div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="brush:php;toolbar:false">标签的主要作用:预格式化的文本。被包围在 pre 元素中的文本通常会保留空格和换行符。如下代码:</p> <pre class="sycode" name="code"><pre class="brush:php;toolbar:false"> var message="欢迎"; for(var i=1;i<=10;i++) { alert(message); }</pre><div class="contentsignin">Copy after login</div></div></pre> <p>在浏览器中的显示结果为:</p> <p> <p></p> </p> <p>在上面的例子中可以看到代码中的空格,换行符都保留下来。如果用以前的方法,回车需要输入<br>签,空格需要输入 </p> <p>注意:<div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="brush:php;toolbar:false"> 标签不只是为显示计算机的源代码时用的,在你需要在网页中预显示格式时都可以使用它,只是<pre class="brush:php;toolbar:false">标签的一个常见应用就是用来展示计算机的源代码。</p> <hr /> <h2><strong>使用<ul>,添加新闻信息列表</strong></h2> <p>在浏览网页时,你会发现网页上有很多信息的列表,如新闻列表、图片列表,如下图所示。</p> <p> <p></p> </p> <p>这些列表就可以使用ul-li标签来完成。ul-li是 <strong>没有前后顺序的信息列表</strong>。</p> <p>语法: </p> <pre class="sycode" name="code"><ul> <li>信息</li> <li>信息</li> ......</ul></pre><div class="contentsignin">Copy after login</div></div> <p>举例: </p> <div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="sycode" name="code"><ul> <li>精彩少年</li> <li>美丽突然出现</li> <li>触动心灵的旋律</li></ul></pre><div class="contentsignin">Copy after login</div></div> <p>ul-li在网页中显示的默认样式一般为:每项li前都自带一个圆点,如下图所示:</p> <p> <p></p> </p> <hr /> <h2><strong>使用<ol>,添加顺序列表</strong></h2> <p>如果想在网页中展示有前后顺序的信息列表,怎么办呢?如,当当网上的书籍热卖排行榜,如下图所示。这类信息展示就可以使用<ol>标签来制作有序列表来展示。</p> <p> <p></p> </p> <p>语法:</p> <div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="sycode" name="code"><ol> <li>信息</li> <li>信息</li> ......</ol></pre><div class="contentsignin">Copy after login</div></div> <p>举例:</p> <p>下面是一个热点课程下载排行榜: </p> <div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="sycode" name="code"><ol> <li>前端开发面试心法 </li> <li>零基础学习html</li> <li>JavaScript全攻略</li></ol></pre><div class="contentsignin">Copy after login</div></div> <p><ol>在网页中显示的默认样式一般为:每项<li>前都自带一个序号,序号默认从1开始,如下图所示:</p> <p> <p></p> </p> <hr /> <h2><strong>初识div</strong></h2> <h3><strong>认识div在排版中的作用</strong></h3> <p>在网页制作过程过中,可以把一些独立的逻辑部分划分出来,放在一个<div>标签中,这个<div>标签的作用就相当于一个容器。 </p> <p>语法:<div>…</div></p> <p>确定逻辑部分:什么是逻辑部分?它是页面上相互关联的一组元素。如网页中的独立的栏目版块,就是一个典型的逻辑部分。如下图所示:图中用红色边框标出的部分就是一个逻辑部分,就可以使用<div>标签作为容器。</p> <p> <p></p> </p> <h3><strong>给div命名,使逻辑更加清晰</strong></h3> <p>在上一小节中,我们把一些标签放进<div>里,划分出一个独立的逻辑部分。为了使逻辑更加清晰,我们可以为这一个独立的逻辑部分设置一个名称,用id属性来为<div>提供唯一的名称,这个就像我们每个人都有一个身份证号,这个身份证号是唯一标识我们的身份的,也是必须唯一的。如下两图进行比较,如果设计师把两个图给你,哪个图你看上去能更快的理解呢?是不是右边的那幅图呢。</p> <p> <p></p> </p> <p>语法:<div id="版块名称">…</div></p> <hr /> <h2><strong>table标签,认识网页上的表格</strong></h2> <h3><strong>table标签 = 我们平时看到到表格</strong></h3> <p>有时候我们需要在网页上展示一些数据,如某公司想在网页上展示公司的库存清单。如下表:</p> <p> <p></p> </p> <p>想在网页上展示上述表格效果可以使用以下代码:</p> <p> <p></p> </p> <p>创建表格的四个元素: table、tbody、tr、th、td</p> <ol> <li><p><table>…</table>:整个表格以<table>标记开始、</table>标记结束。</p></li> <li><p><tbody>…</tbody>:当表格内容非常多时,表格会下载一点显示一点,但如果加上<tbody>标签后,这个表格就要等表格内容全部下载完才会显示。</p></li> <li><p><tr>…</tr>:表格的一行,所以有几对tr 表格就有几行。</p></li> <li><p><td>…</td>:表格的一个单元格,一行中包含几对<td>...</td>,说明一行中就有几列。</p></li> <li><p><th>…</th>:表格的头部的一个单元格,表格表头。</p></li> <li><p>表格中列的个数,取决于一行中数据单元格的个数。 </p></li> </ol> <p>上述代码在浏览器中显示的默认的样式为:</p> <p> <p></p> </p> <p>总结:</p> <ol> <li><p>table表格在没有添加css样式之前,在浏览器中显示是没有表格线的</p></li> <li><p>表头,也就是th标签中的文本默认为粗体并且居中显示</p></li> </ol> <h3><strong>用css样式,为表格加入边框</strong></h3> <p>Table 表格在没有添加 css 样式之前,是没有边框的。这样不便于我们后期合并单元格知识点的讲解,所以在这一节中我们为表格添加一些样式,为它添加边框。代码中加入: </p> <div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="sycode" name="code"><style type="text/css">table tr td,th{border:1px solid #000;}</style></pre><div class="contentsignin">Copy after login</div></div> <p>上述代码是用 css 样式代码,为th,td单元格添加粗细为一个像素的黑色边框。</p> <p>结果窗口显示出结果样式:</p> <p> <p></p> </p> <h3><strong>caption标签,为表格添加标题和摘要</strong></h3> <p>表格还是需要添加一些标签进行优化,可以添加标题和摘要。代码如下 </p> <p> <p></p> </p> <p><strong>摘要</strong> 摘要的内容是不会在浏览器中显示出来的。它的作用是增加表格的可读性(语义化),使搜索引擎更好的读懂表格内容,还可以使屏幕阅读器更好的帮助特殊用户读取表格内容。语法:<table summary="表格简介文本"> </p> <p><strong>标题</strong> 用以描述表格内容,标题的显示位置:表格上方。语法:</p> <div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="sycode" name="code"><table> <caption>标题文本</caption> <tr> <td>…</td> <td>…</td> … </tr>…</table></pre><div class="contentsignin">Copy after login</div></div> <hr /> <h2><strong>初识<a>标签</strong></h2> <h3><strong>使用<a>标签,链接到另一个页面</strong></h3> <p>使用<a>标签可实现超链接,它在网页制作中可以说是无处不在,只要有链接的地方,就会有这个标签。 </p> <p>语法 :<a href="目标网址" title="鼠标滑过显示的文本">链接显示的文本</a> </p> <p>例如:<a href="http://www.zhaolion.com" title="点击进入我的博客">click here!</a></p> <p>上面例子作用是单击click here!文字,网页链接到http://www.zhaolion.com这个网页。 </p> <p>title属性的作用,鼠标滑过链接文字时会显示这个属性的文本内容。这个属性在实际网页开发中作用很大,主要方便搜索引擎了解链接地址的内容(语义化更友好)<strong>提醒</strong>还有一个有趣的现象不知道小伙伴们发现了没有,只要为文本加入a标签后,文字的颜色就会自动变为蓝色(被点击过的文本颜色为紫色),颜色很难看吧,不过没有关系后面我们学习了css样子就可以设置过来(a{color:#000}),后面会详细讲解。</p> <h3><strong>在新建浏览器窗口中打开链接</strong></h3> <p><a>标签在默认情况下,链接的网页是在当前浏览器窗口中打开,有时我们需要在新的浏览器窗口中打开。只需要添加一个属性 target="_blank"如下代码:<a href="目标网址" target="_blank">click here!</a> </p> <h3><strong>使用mailto在网页中链接Email地址</strong></h3> <p><a>标签还有一个作用是可以链接Email地址,使用mailto能让访问者便捷向网站管理者发送电子邮件。我们还可以利用mailto做许多其它事情。下面一一进行讲解,请看详细图示:</p> <p> <p></p> </p> <p><strong>提醒</strong>:如果mailto后面同时有多个参数的话,第一个参数必须以“?”开头,后面的参数每一个都以“&”分隔。下面是一个完整的实例: 在浏览器中显示的一个发送按钮</p> <p> <p></p> </p> <p>点击链接会打开电子邮件应用,并自动填写收件人等设置好的信息,如下图:</p> <p> <p></p> </p> <hr /> <h2><strong>认识<img alt="HTML 入门笔记 - 初识HTML_html/css_WEB-ITnose" >标签,为网页插入图片</strong></h2> <p>在网页的制作中为使网页炫丽美观,肯定是缺少不了图片,可以使用<img alt="HTML 入门笔记 - 初识HTML_html/css_WEB-ITnose" >标签来插入图片。语法: [站外图片上传中……(48)] </p> <p>举例: <img src = "myimage.gif" alt = "My Image" title = "My Image" /> </p> <p>讲解:</p> <ol> <li><p>src:标识图像的位置;</p></li> <li><p>alt:指定图像的描述性文本,当图像不可见时(下载不成功时),可看到该属性指定的文本;</p></li> <li><p>title:提供在图像可见时对图像的描述(鼠标滑过图片时显示的文本);</p></li> <li><p>图像可以是GIF,PNG,JPEG格式的图像文件。 </p></li> </ol> <hr /> <h2><strong>认识表单</strong></h2> <h3><strong>使用表单标签,与用户交互</strong></h3> <p>网站怎样与用户进行交互?答案是使用HTML表单(form)。表单是可以把浏览者输入的数据传送到服务器端,这样服务器端程序就可以处理表单传过来的数据。 </p> <p>语法: <form method="传送方式" action="服务器文件"> </p> <p>讲解:</p> <ol> <li><p><form> :<form>标签是成对出现的,以<form>开始,以</form>结束。</p></li> <li><p>action :浏览者输入的数据被传送到的地方,比如一个PHP页面(save.php)。</p></li> <li><p>method : 数据传送的方式(get/post)。</p><div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="sycode" name="code"><form method="post" action="save.php"> <label for="username">用户名:</label> <input type="text" name="username" /> <label for="pass">密码:</label> <input type="password" name="pass" /></form></pre><div class="contentsignin">Copy after login</div></div></li> </ol> <p><strong>注意</strong> </p> <ol> <li><p>所有表单控件(文本框、文本域、按钮、单选框、复选框等)都必须放在<form></form>标签之间(否则用户输入的信息可提交不到服务器上哦!)。</p></li> <li><p>method:post/get的区别这一部分内容属于后端程序员考虑的问题。感兴趣的小伙伴可以问谷哥 </p></li> </ol> <h3><strong>文本输入框、密码输入框</strong></h3> <p>当用户要在表单中键入字母、数字等内容时,就会用到文本输入框。文本框也可以转化为密码输入框。</p> <p>语法:</p> <div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="sycode" name="code"><form> <input type="text/password" name="名称" value="文本" /></form></pre><div class="contentsignin">Copy after login</div></div> <ol> <li><p>type:</p> <ul> <li>当type="text"时,输入框为文本输入框;</li> <li>当type="password"时, 输入框为密码输入框。</li> </ul></li> <li><p>name:为文本框命名,以备后台程序ASP 、PHP使用。</p></li> <li><p>value:为文本输入框设置默认值。(一般起到提示作用)</p></li> </ol> <p>举例:</p> <div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="sycode" name="code"><form> 姓名: <input type="text" name="myName"> <br/> 密码: <input type="password" name="pass"></form></pre><div class="contentsignin">Copy after login</div></div> <p>在浏览器中显示的结果:</p> <p> <p></p> </p> <h3><strong>文本域,支持多行文本输入</strong></h3> <p>当用户需要在表单中输入大段文字时,需要用到文本输入域。 </p> <p>语法: <textarea rows="行数" cols="列数">文本</textarea> </p> <ol> <li><p><textarea>标签是成对出现的,以<textarea>开始,以</textarea>结束。</p></li> <li><p>cols :多行输入域的列数。</p></li> <li><p>rows :多行输入域的行数。</p></li> <li><p>在<textarea></textarea>标签之间可以输入默认值。</p></li> </ol> <p>举例: </p> <div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="sycode" name="code"><form method="post" action="save.php"> <label>联系我们</label> <textarea cols="50" rows="10" >在这里输入内容...</textarea></form></pre><div class="contentsignin">Copy after login</div></div> <p>在浏览器中显示结果:</p> <p> <p></p> </p> <h3><strong>使用单选框、复选框,让用户选择</strong></h3> <p>在使用表单设计调查表时,为了减少用户的操作,使用选择框是一个好主意,html中有两种选择框,即单选框和复选框,两者的区别是单选框中的选项用户只能选择一项,而复选框中用户可以任意选择多项,甚至全选。请看下面的例子:语法: <input type="radio/checkbox" value="值" name="名称" checked="checked"/></p> <ol> <li><p>type:</p> <ul> <li><p>当 type="radio" 时,控件为单选框</p></li> <li><p>当 type="checkbox" 时,控件为复选框</p></li> </ul></li> <li><p>value:提交数据到服务器的值(后台程序PHP使用)</p></li> <li><p>name:为控件命名,以备后台程序 ASP、PHP 使用</p></li> <li><p>checked:当设置 checked="checked" 时,该选项被默认选中</p></li> </ol> <p>如下面代码:</p> <p> <p></p> </p> <p>在浏览器中显示的结果:</p> <p> <p></p> </p> <p><strong>注意</strong>:同一组的单选按钮,name 取值一定要一致,比如上面例子为同一个名称“radioLove”,这样同一组的单选按钮才可以起到单选的作用。</p> <h3><strong>使用下拉列表框,节省空间</strong></h3> <p>下拉列表在网页中也常会用到,它可以有效的节省网页空间。既可以单选、又可以多选。如下代码:</p> <p> <p></p> </p> <p>讲解:</p> <ol> <li>value: <p> <p></p> </p> </li> <li>selected="selected":设置selected="selected"属性,则该选项就被默认选中。</li> </ol> <h3><strong>使用下拉列表框进行多选</strong></h3> <p>下拉列表也可以进行多选操作,在<select>标签中设置multiple="multiple"属性,就可以实现多选功能,在 widows 操作系统下,进行多选时按下Ctrl键同时进行单击(在 Mac下使用 Command +单击),可以选择多个选项。如下代码:</p> <p> <p></p> </p> <p>在浏览器中显示的结果:</p> <p> <p></p> </p> <h3><strong>使用提交按钮,提交数据</strong></h3> <p>在表单中有两种按钮可以使用,分别为:提交按钮、重置。这一小节讲解提交按钮:当用户需要提交表单信息到服务器时,需要用到提交按钮。语法: <input type="submit" value="提交"> </p> <ol> <li>type:只有当type值设置为submit时,按钮才有提交作用</li> <li>value:按钮上显示的文字 </li> </ol> <p>举例:</p> <p> <p></p> </p> <p>在浏览器中显示的结果:</p> <p> <p></p> </p> <h3><strong>使用重置按钮,重置表单信息</strong></h3> <p>当用户需要重置表单信息到初始时的状态时,比如用户输入“用户名”后,发现书写有误,可以使用重置按钮使输入框恢复到初始状态。只需要把type设置为"reset"就可以。语法: <input type="reset" value="重置"> </p> <ol> <li>type:只有当type值设置为reset时,按钮才有重置作用 </li> <li>value:按钮上显示的文字 </li> </ol> <p>举例: </p> <p> <p></p> </p> <p>在浏览器中显示的结果:输入账号</p> <p> <p></p> </p> <p>单击重置按钮</p> <p> <p></p> </p> <h3><strong>form表单中的label标签</strong></h3> <p>小伙伴们,你们在前面学习表单各种控件的时候,有没有发现一个标签--label,这一小节就来揭晓它的作用。label标签不会向用户呈现任何特殊效果,它的作用是为鼠标用户改进了可用性。如果你在 label 标签内点击文本,就会触发此控件。就是说,当用户单击选中该label标签时,浏览器就会自动将焦点转到和标签相关的表单控件上(就自动选中和该label标签相关连的表单控件上)。语法: <label for="控件id名称"><strong>注意</strong> 标签的 for 属性中的值应当与相关控件的 id 属性值一定要相同。 <strong>这样你会在点慢跑标签,即使没有点checkbox 也能选中</strong>例子:</p> <div class="code" style="position:relative; padding:0px; margin:0px;"><pre class="sycode" name="code"><form> <a>你对什么运动感兴趣:</a> <br /> <label for="1">慢跑</label><input type="checkbox" name="manpao" id="1"><br /> <label for="2">登山</label><input type="checkbox" name="dengshan" id="2"><br /> <label for="3">篮球</label><input type="checkbox" name="lanqiu" id="3"><br /></form></pre><div class="contentsignin">Copy after login</div></div> </div> </div> <div style="height: 25px;"> <div class="wzconBq" style="display: inline-flex;"> <span>Related labels:</span> <div class="wzcbqd"> <a onclick="hits_log(2,'www',this);" href-data="https://www.php.cn/search?word=html入门笔记-初识html" target="_blank">HTML 入门笔记 - 初识HTML</a> </div> </div> <div style="display: inline-flex;float: right; color:#333333;">source:php.cn</div> </div> <div class="wzconOtherwz"> <a href="https://www.php.cn/faq/269614.html" title="前端碎语(6)_html/css_WEB-ITnose"> <span>Previous article:前端碎语(6)_html/css_WEB-ITnose</span> </a> <a href="https://www.php.cn/faq/269622.html" title="HTML系列(六):划分文档结构_html/css_WEB-ITnose"> <span>Next article:HTML系列(六):划分文档结构_html/css_WEB-ITnose</span> </a> </div> <div class="wzconShengming"> <div class="bzsmdiv">Statement of this Website</div> <div>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</div> </div> <ins class="adsbygoogle" style="display:block" data-ad-format="autorelaxed" data-ad-client="ca-pub-5902227090019525" data-ad-slot="2507867629"></ins> <script> (adsbygoogle = window.adsbygoogle || []).push({}); </script> <div class="wzconZzwz"> <div class="wzconZzwztitle">Latest Articles by Author</div> <ul> <li> <div class="wzczzwzli"> <span class="layui-badge-dots"></span> <a target="_blank" href="https://www.php.cn/faq/1796639331.html">What is a NullPointerException, and how do I fix it?</a> </div> <div>2024-10-22 09:46:29</div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots"></span> <a target="_blank" href="https://www.php.cn/faq/1796629482.html">From Novice to Coder: Your Journey Begins with C Fundamentals</a> </div> <div>2024-10-13 13:53:41</div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots"></span> <a target="_blank" href="https://www.php.cn/faq/1796628545.html">Unlocking Web Development with PHP: A Beginner's Guide</a> </div> <div>2024-10-12 12:15:51</div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots"></span> <a target="_blank" href="https://www.php.cn/faq/1796627928.html">Demystifying C: A Clear and Simple Path for New Programmers</a> </div> <div>2024-10-11 22:47:31</div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots"></span> <a target="_blank" href="https://www.php.cn/faq/1796627806.html">Unlock Your Coding Potential: C Programming for Absolute Beginners</a> </div> <div>2024-10-11 19:36:51</div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots"></span> <a target="_blank" href="https://www.php.cn/faq/1796627670.html">Unleash Your Inner Programmer: C for Absolute Beginners</a> </div> <div>2024-10-11 15:50:41</div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots"></span> <a target="_blank" href="https://www.php.cn/faq/1796627643.html">Automate Your Life with C: Scripts and Tools for Beginners</a> </div> <div>2024-10-11 15:07:41</div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots"></span> <a target="_blank" href="https://www.php.cn/faq/1796627620.html">PHP Made Easy: Your First Steps in Web Development</a> </div> <div>2024-10-11 14:21:21</div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots"></span> <a target="_blank" href="https://www.php.cn/faq/1796627574.html">Build Anything with Python: A Beginner's Guide to Unleashing Your Creativity</a> </div> <div>2024-10-11 12:59:11</div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots"></span> <a target="_blank" href="https://www.php.cn/faq/1796627539.html">The Key to Coding: Unlocking the Power of Python for Beginners</a> </div> <div>2024-10-11 12:17:31</div> </li> </ul> </div> <div class="wzconZzwz"> <div class="wzconZzwztitle">Latest Issues</div> <div class="wdsyContent"> <div class="wdsyConDiv flexRow wdsyConDiv1"> <div class="wdcdContent flexColumn"> <a href="https://www.php.cn/wenda/176411.html" target="_blank" title="function_exists() cannot determine the custom function" class="wdcdcTitle">function_exists() cannot determine the custom function</a> <a href="https://www.php.cn/wenda/176411.html" class="wdcdcCons">Function test () {return true;} if (function_exists ('test')) {echo "test is function...</a> <div class="wdcdcInfo flexRow"> <div class="wdcdcileft"> <span class="wdcdciSpan"> From 2024-04-29 11:01:01</span> </div> <div class="wdcdciright flexRow"> <div class="wdcdcirdz flexRow ira"> <b class="wdcdcirdzi"></b>0 </div> <div class="wdcdcirpl flexRow ira"><b class="wdcdcirpli"></b>3</div> <div class="wdcdcirwatch flexRow ira"><b class="wdcdcirwatchi"></b>2039</div> </div> </div> </div> </div> <div class="wdsyConLine wdsyConLine2"></div> <div class="wdsyConDiv flexRow wdsyConDiv1"> <div class="wdcdContent flexColumn"> <a href="https://www.php.cn/wenda/176410.html" target="_blank" title="How to display the mobile version of Google Chrome" class="wdcdcTitle">How to display the mobile version of Google Chrome</a> <a href="https://www.php.cn/wenda/176410.html" class="wdcdcCons">Hello teacher, how can I change Google Chrome into a mobile version?</a> <div class="wdcdcInfo flexRow"> <div class="wdcdcileft"> <span class="wdcdciSpan"> From 2024-04-23 00:22:19</span> </div> <div class="wdcdciright flexRow"> <div class="wdcdcirdz flexRow ira"> <b class="wdcdcirdzi"></b>0 </div> <div class="wdcdcirpl flexRow ira"><b class="wdcdcirpli"></b>11</div> <div class="wdcdcirwatch flexRow ira"><b class="wdcdcirwatchi"></b>2199</div> </div> </div> </div> </div> <div class="wdsyConLine wdsyConLine2"></div> <div class="wdsyConDiv flexRow wdsyConDiv1"> <div class="wdcdContent flexColumn"> <a href="https://www.php.cn/wenda/176407.html" target="_blank" title="The child window operates the parent window, but the output does not respond." class="wdcdcTitle">The child window operates the parent window, but the output does not respond.</a> <a href="https://www.php.cn/wenda/176407.html" class="wdcdcCons">The first two sentences are executable, but the last sentence cannot be implemented.</a> <div class="wdcdcInfo flexRow"> <div class="wdcdcileft"> <span class="wdcdciSpan"> From 2024-04-19 15:37:47</span> </div> <div class="wdcdciright flexRow"> <div class="wdcdcirdz flexRow ira"> <b class="wdcdcirdzi"></b>0 </div> <div class="wdcdcirpl flexRow ira"><b class="wdcdcirpli"></b>1</div> <div class="wdcdcirwatch flexRow ira"><b class="wdcdcirwatchi"></b>1853</div> </div> </div> </div> </div> <div class="wdsyConLine wdsyConLine2"></div> <div class="wdsyConDiv flexRow wdsyConDiv1"> <div class="wdcdContent flexColumn"> <a href="https://www.php.cn/wenda/176406.html" target="_blank" title="There is no output in the parent window" class="wdcdcTitle">There is no output in the parent window</a> <a href="https://www.php.cn/wenda/176406.html" class="wdcdcCons">document.onclick = function(){ window.opener.document.write('I am the output of the child ...</a> <div class="wdcdcInfo flexRow"> <div class="wdcdcileft"> <span class="wdcdciSpan"> From 2024-04-18 23:52:34</span> </div> <div class="wdcdciright flexRow"> <div class="wdcdcirdz flexRow ira"> <b class="wdcdcirdzi"></b>0 </div> <div class="wdcdcirpl flexRow ira"><b class="wdcdcirpli"></b>1</div> <div class="wdcdcirwatch flexRow ira"><b class="wdcdcirwatchi"></b>1745</div> </div> </div> </div> </div> <div class="wdsyConLine wdsyConLine2"></div> <div class="wdsyConDiv flexRow wdsyConDiv1"> <div class="wdcdContent flexColumn"> <a href="https://www.php.cn/wenda/176405.html" target="_blank" title="Where is the courseware about CSS mind mapping?" class="wdcdcTitle">Where is the courseware about CSS mind mapping?</a> <a href="https://www.php.cn/wenda/176405.html" class="wdcdcCons">Courseware</a> <div class="wdcdcInfo flexRow"> <div class="wdcdcileft"> <span class="wdcdciSpan"> From 2024-04-16 10:10:18</span> </div> <div class="wdcdciright flexRow"> <div class="wdcdcirdz flexRow ira"> <b class="wdcdcirdzi"></b>0 </div> <div class="wdcdcirpl flexRow ira"><b class="wdcdcirpli"></b>0</div> <div class="wdcdcirwatch flexRow ira"><b class="wdcdcirwatchi"></b>1765</div> </div> </div> </div> </div> <div class="wdsyConLine wdsyConLine2"></div> </div> </div> <div class="wzconZt" > <div class="wzczt-title"> <div>Related Topics</div> <a href="https://www.php.cn/faq/zt" target="_blank">More> </a> </div> <div class="wzcttlist"> <ul> <li class="ul-li"> <a target="_blank" href="https://www.php.cn/faq/htmlzmzsdm"><img src="https://img.php.cn/upload/subject/202407/22/2024072213501620616.jpg?x-oss-process=image/resize,m_fill,h_145,w_220" alt="How to comment code in html" /> </a> <a target="_blank" href="https://www.php.cn/faq/htmlzmzsdm" class="title-a-spanl" title="How to comment code in html"><span>How to comment code in html</span> </a> </li> <li class="ul-li"> <a target="_blank" href="https://www.php.cn/faq/szhbsyff"><img src="https://img.php.cn/upload/subject/202407/22/2024072213232546779.jpg?x-oss-process=image/resize,m_fill,h_145,w_220" alt="How to use digital currency" /> </a> <a target="_blank" href="https://www.php.cn/faq/szhbsyff" class="title-a-spanl" title="How to use digital currency"><span>How to use digital currency</span> </a> </li> <li class="ul-li"> <a target="_blank" href="https://www.php.cn/faq/sdxnbhqzxjg"><img src="https://img.php.cn/upload/subject/202407/22/2024072213230975525.jpg?x-oss-process=image/resize,m_fill,h_145,w_220" alt="The latest prices of the top ten virtual currencies" /> </a> <a target="_blank" href="https://www.php.cn/faq/sdxnbhqzxjg" class="title-a-spanl" title="The latest prices of the top ten virtual currencies"><span>The latest prices of the top ten virtual currencies</span> </a> </li> <li class="ul-li"> <a target="_blank" href="https://www.php.cn/faq/vbljsjkdff"><img src="https://img.php.cn/upload/subject/202407/22/2024072213570046036.jpg?x-oss-process=image/resize,m_fill,h_145,w_220" alt="How to connect to database using vb" /> </a> <a target="_blank" href="https://www.php.cn/faq/vbljsjkdff" class="title-a-spanl" title="How to connect to database using vb"><span>How to connect to database using vb</span> </a> </li> <li class="ul-li"> <a target="_blank" href="https://www.php.cn/faq/iphoneyjsssj"><img src="https://img.php.cn/upload/subject/202407/22/2024072211500910557.jpg?x-oss-process=image/resize,m_fill,h_145,w_220" alt="iPhone 16 expected launch time" /> </a> <a target="_blank" href="https://www.php.cn/faq/iphoneyjsssj" class="title-a-spanl" title="iPhone 16 expected launch time"><span>iPhone 16 expected launch time</span> </a> </li> <li class="ul-li"> <a target="_blank" href="https://www.php.cn/faq/linuxgshypdff"><img src="https://img.php.cn/upload/subject/202407/22/2024072213282690793.jpg?x-oss-process=image/resize,m_fill,h_145,w_220" alt="How to format hard drive in linux" /> </a> <a target="_blank" href="https://www.php.cn/faq/linuxgshypdff" class="title-a-spanl" title="How to format hard drive in linux"><span>How to format hard drive in linux</span> </a> </li> <li class="ul-li"> <a target="_blank" href="https://www.php.cn/faq/javadcexcel"><img src="https://img.php.cn/upload/subject/202407/22/2024072214180495061.jpg?x-oss-process=image/resize,m_fill,h_145,w_220" alt="java export excel" /> </a> <a target="_blank" href="https://www.php.cn/faq/javadcexcel" class="title-a-spanl" title="java export excel"><span>java export excel</span> </a> </li> <li class="ul-li"> <a target="_blank" href="https://www.php.cn/faq/dsjpt"><img src="https://img.php.cn/upload/subject/202407/22/2024072214391327550.jpg?x-oss-process=image/resize,m_fill,h_145,w_220" alt="Big data platform" /> </a> <a target="_blank" href="https://www.php.cn/faq/dsjpt" class="title-a-spanl" title="Big data platform"><span>Big data platform</span> </a> </li> </ul> </div> </div> </div> </div> <div class="phpwzright"> <ins class="adsbygoogle" style="display:block" data-ad-client="ca-pub-5902227090019525" data-ad-slot="3653428331" data-ad-format="auto" data-full-width-responsive="true"></ins> <script> (adsbygoogle = window.adsbygoogle || []).push({}); </script> <div class="wzrOne"> <div class="wzroTitle">Popular Recommendations</div> <div class="wzroList"> <ul> <li> <div class="wzczzwzli"> <span class="layui-badge-dots wzrolr"></span> <a style="height: auto;" title="What does url mean?" href="https://www.php.cn/faq/418772.html">What does url mean?</a> </div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots wzrolr"></span> <a style="height: auto;" title="What does DOM mean?" href="https://www.php.cn/faq/414303.html">What does DOM mean?</a> </div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots wzrolr"></span> <a style="height: auto;" title="How to change image size" href="https://www.php.cn/faq/414252.html">How to change image size</a> </div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots wzrolr"></span> <a style="height: auto;" title="How to make font bold in HTML" href="https://www.php.cn/faq/414520.html">How to make font bold in HTML</a> </div> </li> <li> <div class="wzczzwzli"> <span class="layui-badge-dots wzrolr"></span> <a style="height: auto;" title="How to set the size of html images" href="https://www.php.cn/faq/475145.html">How to set the size of html images</a> </div> </li> </ul> </div> </div> <script src="https://sw.php.cn/hezuo/cac1399ab368127f9b113b14eb3316d0.js" type="text/javascript"></script> <div class="wzrThree"> <div class="wzrthree-title"> <div>Popular Tutorials</div> <a target="_blank" href="https://www.php.cn/course.html">More> </a> </div> <div class="wzrthreelist swiper2"> <div class="wzrthreeTab swiper-wrapper"> <div class="check tabdiv swiper-slide" data-id="one">Related Tutorials <div></div></div> <div class="tabdiv swiper-slide" data-id="two">Popular Recommendations<div></div></div> <div class="tabdiv swiper-slide" data-id="three">Latest courses<div></div></div> </div> <ul class="one"> <li> <a target="_blank" href="https://www.php.cn/course/812.html" title="The latest ThinkPHP 5.1 world premiere video tutorial (60 days to become a PHP expert online training course)" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/041/620debc3eab3f377.jpg" alt="The latest ThinkPHP 5.1 world premiere video tutorial (60 days to become a PHP expert online training course)"/> </a> <div class="wzrthree-right"> <a target="_blank" title="The latest ThinkPHP 5.1 world premiere video tutorial (60 days to become a PHP expert online training course)" href="https://www.php.cn/course/812.html">The latest ThinkPHP 5.1 world premiere video tutorial (60 days to become a PHP expert online training course)</a> <div class="wzrthreerb"> <div>1421119 <b class="kclbcollectb"></b></div> <div class="courseICollection" data-id="812"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/74.html" title="PHP introductory tutorial one: Learn PHP in one week" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/068/6253d1e28ef5c345.png" alt="PHP introductory tutorial one: Learn PHP in one week"/> </a> <div class="wzrthree-right"> <a target="_blank" title="PHP introductory tutorial one: Learn PHP in one week" href="https://www.php.cn/course/74.html">PHP introductory tutorial one: Learn PHP in one week</a> <div class="wzrthreerb"> <div>4264735 <b class="kclbcollectb"></b></div> <div class="courseICollection" data-id="74"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/286.html" title="JAVA Beginner's Video Tutorial" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/068/62590a2bacfd9379.png" alt="JAVA Beginner's Video Tutorial"/> </a> <div class="wzrthree-right"> <a target="_blank" title="JAVA Beginner's Video Tutorial" href="https://www.php.cn/course/286.html">JAVA Beginner's Video Tutorial</a> <div class="wzrthreerb"> <div>2515058 <b class="kclbcollectb"></b></div> <div class="courseICollection" data-id="286"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/504.html" title="Little Turtle's zero-based introduction to learning Python video tutorial" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/068/62590a67ce3a6655.png" alt="Little Turtle's zero-based introduction to learning Python video tutorial"/> </a> <div class="wzrthree-right"> <a target="_blank" title="Little Turtle's zero-based introduction to learning Python video tutorial" href="https://www.php.cn/course/504.html">Little Turtle's zero-based introduction to learning Python video tutorial</a> <div class="wzrthreerb"> <div>506120 <b class="kclbcollectb"></b></div> <div class="courseICollection" data-id="504"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/2.html" title="PHP zero-based introductory tutorial" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/068/6253de27bc161468.png" alt="PHP zero-based introductory tutorial"/> </a> <div class="wzrthree-right"> <a target="_blank" title="PHP zero-based introductory tutorial" href="https://www.php.cn/course/2.html">PHP zero-based introductory tutorial</a> <div class="wzrthreerb"> <div>861225 <b class="kclbcollectb"></b></div> <div class="courseICollection" data-id="2"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> </ul> <ul class="two" style="display: none;"> <li> <a target="_blank" href="https://www.php.cn/course/812.html" title="The latest ThinkPHP 5.1 world premiere video tutorial (60 days to become a PHP expert online training course)" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/041/620debc3eab3f377.jpg" alt="The latest ThinkPHP 5.1 world premiere video tutorial (60 days to become a PHP expert online training course)"/> </a> <div class="wzrthree-right"> <a target="_blank" title="The latest ThinkPHP 5.1 world premiere video tutorial (60 days to become a PHP expert online training course)" href="https://www.php.cn/course/812.html">The latest ThinkPHP 5.1 world premiere video tutorial (60 days to become a PHP expert online training course)</a> <div class="wzrthreerb"> <div >1421119 times of learning</div> <div class="courseICollection" data-id="812"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/286.html" title="JAVA Beginner's Video Tutorial" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/068/62590a2bacfd9379.png" alt="JAVA Beginner's Video Tutorial"/> </a> <div class="wzrthree-right"> <a target="_blank" title="JAVA Beginner's Video Tutorial" href="https://www.php.cn/course/286.html">JAVA Beginner's Video Tutorial</a> <div class="wzrthreerb"> <div >2515058 times of learning</div> <div class="courseICollection" data-id="286"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/504.html" title="Little Turtle's zero-based introduction to learning Python video tutorial" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/068/62590a67ce3a6655.png" alt="Little Turtle's zero-based introduction to learning Python video tutorial"/> </a> <div class="wzrthree-right"> <a target="_blank" title="Little Turtle's zero-based introduction to learning Python video tutorial" href="https://www.php.cn/course/504.html">Little Turtle's zero-based introduction to learning Python video tutorial</a> <div class="wzrthreerb"> <div >506120 times of learning</div> <div class="courseICollection" data-id="504"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/901.html" title="Quick introduction to web front-end development" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/067/64be28a53a4f6310.png" alt="Quick introduction to web front-end development"/> </a> <div class="wzrthree-right"> <a target="_blank" title="Quick introduction to web front-end development" href="https://www.php.cn/course/901.html">Quick introduction to web front-end development</a> <div class="wzrthreerb"> <div >215599 times of learning</div> <div class="courseICollection" data-id="901"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/234.html" title="Master PS video tutorials from scratch" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/068/62611f57ed0d4840.jpg" alt="Master PS video tutorials from scratch"/> </a> <div class="wzrthree-right"> <a target="_blank" title="Master PS video tutorials from scratch" href="https://www.php.cn/course/234.html">Master PS video tutorials from scratch</a> <div class="wzrthreerb"> <div >885800 times of learning</div> <div class="courseICollection" data-id="234"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> </ul> <ul class="three" style="display: none;"> <li> <a target="_blank" href="https://www.php.cn/course/1648.html" title="[Web front-end] Node.js quick start" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/067/662b5d34ba7c0227.png" alt="[Web front-end] Node.js quick start"/> </a> <div class="wzrthree-right"> <a target="_blank" title="[Web front-end] Node.js quick start" href="https://www.php.cn/course/1648.html">[Web front-end] Node.js quick start</a> <div class="wzrthreerb"> <div >7188 times of learning</div> <div class="courseICollection" data-id="1648"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/1647.html" title="Complete collection of foreign web development full-stack courses" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/067/6628cc96e310c937.png" alt="Complete collection of foreign web development full-stack courses"/> </a> <div class="wzrthree-right"> <a target="_blank" title="Complete collection of foreign web development full-stack courses" href="https://www.php.cn/course/1647.html">Complete collection of foreign web development full-stack courses</a> <div class="wzrthreerb"> <div >5573 times of learning</div> <div class="courseICollection" data-id="1647"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/1646.html" title="Go language practical GraphQL" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/067/662221173504a436.png" alt="Go language practical GraphQL"/> </a> <div class="wzrthree-right"> <a target="_blank" title="Go language practical GraphQL" href="https://www.php.cn/course/1646.html">Go language practical GraphQL</a> <div class="wzrthreerb"> <div >4694 times of learning</div> <div class="courseICollection" data-id="1646"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/1645.html" title="550W fan master learns JavaScript from scratch step by step" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/067/662077e163124646.png" alt="550W fan master learns JavaScript from scratch step by step"/> </a> <div class="wzrthree-right"> <a target="_blank" title="550W fan master learns JavaScript from scratch step by step" href="https://www.php.cn/course/1645.html">550W fan master learns JavaScript from scratch step by step</a> <div class="wzrthreerb"> <div >671 times of learning</div> <div class="courseICollection" data-id="1645"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> <li> <a target="_blank" href="https://www.php.cn/course/1644.html" title="Python master Mosh, a beginner with zero basic knowledge can get started in 6 hours" class="wzrthreelaimg"> <img src="https://img.php.cn/upload/course/000/000/067/6616418ca80b8916.png" alt="Python master Mosh, a beginner with zero basic knowledge can get started in 6 hours"/> </a> <div class="wzrthree-right"> <a target="_blank" title="Python master Mosh, a beginner with zero basic knowledge can get started in 6 hours" href="https://www.php.cn/course/1644.html">Python master Mosh, a beginner with zero basic knowledge can get started in 6 hours</a> <div class="wzrthreerb"> <div >23709 times of learning</div> <div class="courseICollection" data-id="1644"> <b class="nofollow small-nocollect"></b> </div> </div> </div> </li> </ul> </div> <script> var mySwiper = new Swiper('.swiper2', { autoplay: false,//可选选项,自动滑动 slidesPerView : 'auto', }) $('.wzrthreeTab>div').click(function(e){ $('.wzrthreeTab>div').removeClass('check') $(this).addClass('check') $('.wzrthreelist>ul').css('display','none') $('.'+e.currentTarget.dataset.id).show() }) </script> </div> <div class="wzrFour"> <div class="wzrfour-title"> <div>Latest Downloads</div> <a href="https://www.php.cn/xiazai">More> </a> </div> <script> $(document).ready(function(){ var sjyx_banSwiper = new Swiper(".sjyx_banSwiperwz",{ speed:1000, autoplay:{ delay:3500, disableOnInteraction: false, }, pagination:{ el:'.sjyx_banSwiperwz .swiper-pagination', clickable :false, }, loop:true }) }) </script> <div class="wzrfourList swiper3"> <div class="wzrfourlTab swiper-wrapper"> <div class="check swiper-slide" data-id="onef">Web Effects <div></div></div> <div class="swiper-slide" data-id="twof">Website Source Code<div></div></div> <div class="swiper-slide" data-id="threef">Website Materials<div></div></div> <div class="swiper-slide" data-id="fourf">Front End Template<div></div></div> </div> <ul class="onef"> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a target="_blank" title="jQuery enterprise message form contact code" href="https://www.php.cn/toolset/js-special-effects/8071">[form button] jQuery enterprise message form contact code</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a target="_blank" title="HTML5 MP3 music box playback effects" href="https://www.php.cn/toolset/js-special-effects/8070">[Player special effects] HTML5 MP3 music box playback effects</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a target="_blank" title="HTML5 cool particle animation navigation menu special effects" href="https://www.php.cn/toolset/js-special-effects/8069">[Menu navigation] HTML5 cool particle animation navigation menu special effects</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a target="_blank" title="jQuery visual form drag and drop editing code" href="https://www.php.cn/toolset/js-special-effects/8068">[form button] jQuery visual form drag and drop editing code</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a target="_blank" title="VUE.JS imitation Kugou music player code" href="https://www.php.cn/toolset/js-special-effects/8067">[Player special effects] VUE.JS imitation Kugou music player code</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a target="_blank" title="Classic html5 pushing box game" href="https://www.php.cn/toolset/js-special-effects/8066">[html5 special effects] Classic html5 pushing box game</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a target="_blank" title="jQuery scrolling to add or reduce image effects" href="https://www.php.cn/toolset/js-special-effects/8065">[Picture special effects] jQuery scrolling to add or reduce image effects</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a target="_blank" title="CSS3 personal album cover hover zoom effect" href="https://www.php.cn/toolset/js-special-effects/8064">[Photo album effects] CSS3 personal album cover hover zoom effect</a> </div> </li> </ul> <ul class="twof" style="display:none"> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8328" title="Home Decor Cleaning and Repair Service Company Website Template" target="_blank">[Front-end template] Home Decor Cleaning and Repair Service Company Website Template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8327" title="Fresh color personal resume guide page template" target="_blank">[Front-end template] Fresh color personal resume guide page template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8326" title="Designer Creative Job Resume Web Template" target="_blank">[Front-end template] Designer Creative Job Resume Web Template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8325" title="Modern engineering construction company website template" target="_blank">[Front-end template] Modern engineering construction company website template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8324" title="Responsive HTML5 template for educational service institutions" target="_blank">[Front-end template] Responsive HTML5 template for educational service institutions</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8323" title="Online e-book store mall website template" target="_blank">[Front-end template] Online e-book store mall website template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8322" title="IT technology solves Internet company website template" target="_blank">[Front-end template] IT technology solves Internet company website template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8321" title="Purple style foreign exchange trading service website template" target="_blank">[Front-end template] Purple style foreign exchange trading service website template</a> </div> </li> </ul> <ul class="threef" style="display:none"> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-materials/3078" target="_blank" title="Cute summer elements vector material (EPS PNG)">[PNG material] Cute summer elements vector material (EPS PNG)</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-materials/3077" target="_blank" title="Four red 2023 graduation badges vector material (AI EPS PNG)">[PNG material] Four red 2023 graduation badges vector material (AI EPS PNG)</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-materials/3076" target="_blank" title="Singing bird and cart filled with flowers design spring banner vector material (AI EPS)">[banner picture] Singing bird and cart filled with flowers design spring banner vector material (AI EPS)</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-materials/3075" target="_blank" title="Golden graduation cap vector material (EPS PNG)">[PNG material] Golden graduation cap vector material (EPS PNG)</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-materials/3074" target="_blank" title="Black and white style mountain icon vector material (EPS PNG)">[PNG material] Black and white style mountain icon vector material (EPS PNG)</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-materials/3073" target="_blank" title="Superhero silhouette vector material (EPS PNG) with different color cloaks and different poses">[PNG material] Superhero silhouette vector material (EPS PNG) with different color cloaks and different poses</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-materials/3072" target="_blank" title="Flat style Arbor Day banner vector material (AI+EPS)">[banner picture] Flat style Arbor Day banner vector material (AI+EPS)</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-materials/3071" target="_blank" title="Nine comic-style exploding chat bubbles vector material (EPS+PNG)">[PNG material] Nine comic-style exploding chat bubbles vector material (EPS+PNG)</a> </div> </li> </ul> <ul class="fourf" style="display:none"> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8328" target="_blank" title="Home Decor Cleaning and Repair Service Company Website Template">[Front-end template] Home Decor Cleaning and Repair Service Company Website Template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8327" target="_blank" title="Fresh color personal resume guide page template">[Front-end template] Fresh color personal resume guide page template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8326" target="_blank" title="Designer Creative Job Resume Web Template">[Front-end template] Designer Creative Job Resume Web Template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8325" target="_blank" title="Modern engineering construction company website template">[Front-end template] Modern engineering construction company website template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8324" target="_blank" title="Responsive HTML5 template for educational service institutions">[Front-end template] Responsive HTML5 template for educational service institutions</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8323" target="_blank" title="Online e-book store mall website template">[Front-end template] Online e-book store mall website template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8322" target="_blank" title="IT technology solves Internet company website template">[Front-end template] IT technology solves Internet company website template</a> </div> </li> <li> <div class="wzrfourli"> <span class="layui-badge-dots wzrflr"></span> <a href="https://www.php.cn/toolset/website-source-code/8321" target="_blank" title="Purple style foreign exchange trading service website template">[Front-end template] Purple style foreign exchange trading service website template</a> </div> </li> </ul> </div> <script> var mySwiper = new Swiper('.swiper3', { autoplay: false,//可选选项,自动滑动 slidesPerView : 'auto', }) $('.wzrfourlTab>div').click(function(e){ $('.wzrfourlTab>div').removeClass('check') $(this).addClass('check') $('.wzrfourList>ul').css('display','none') $('.'+e.currentTarget.dataset.id).show() }) </script> </div> </div> </div> <footer> <div class="footer"> <div class="footertop"> <img src="/static/imghw/logo.png" alt=""> <p>Public welfare online PHP training,Help PHP learners grow quickly!</p> </div> <div class="footermid"> <a href="https://www.php.cn/about/us.html">About us</a> <a href="https://www.php.cn/about/disclaimer.html">Disclaimer</a> <a href="https://www.php.cn/update/article_0_1.html">Sitemap</a> </div> <div class="footerbottom"> <p> © php.cn All rights reserved </p> </div> </div> </footer> <input type="hidden" id="verifycode" value="/captcha.html"> <script>layui.use(['element', 'carousel'], function () {var element = layui.element;$ = layui.jquery;var carousel = layui.carousel;carousel.render({elem: '#test1', width: '100%', height: '330px', arrow: 'always'});$.getScript('/static/js/jquery.lazyload.min.js', function () {$("img").lazyload({placeholder: "/static/images/load.jpg", effect: "fadeIn", threshold: 200, skip_invisible: false});});});</script> <script src="/static/js/common_new.js"></script> <script type="text/javascript" src="/static/js/jquery.cookie.js?1732854695"></script> <script src="https://vdse.bdstatic.com//search-video.v1.min.js"></script> <link rel='stylesheet' id='_main-css' href='/static/css/viewer.min.css?2' type='text/css' media='all'/> <script type='text/javascript' src='/static/js/viewer.min.js?1'></script> <script type='text/javascript' src='/static/js/jquery-viewer.min.js'></script> <script type="text/javascript" src="/static/js/global.min.js?5.5.53"></script> </body> </html>