博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
引用自己创建的css样式表_如何使用CSS创建联系表
阅读量:2520 次
发布时间:2019-05-11

本文共 2641 字,大约阅读时间需要 8 分钟。

引用自己创建的css样式表

First we create the HTML elements - input fields for First Name, Last Name, Email and a Text Area for the message.

首先,我们创建HTML元素-名字,姓氏,电子邮件和消息的文本区域的输入字段。

Later we apply CSS styles to make the form visually appealing.

后来,我们应用CSS样式使表格具有视觉吸引力。

HTML部分 (The HTML part)

The HTML section has a div with class container with the heading h3Contact Form

HTML部分的div带有类container ,标题为h3Contact Form

The form with name contact_form contains input fields for:

名称为contact_form的表单包含以下输入字段:

  • First Name

    名字
  • Last Name

  • Email

    电子邮件
  • Message

    信息

A div with class center to align the items center. An input type submit to submit the form.The required attribute in the text fields are checked for value on submission.

具有班次center的div以使项目中心对齐。 一个inputsubmit提交form.The required在文本字段属性是为在提交值检查。

Contact Form

CSS部分 (The CSS part)

/* Importing the Roboto font from Google Fonts. */@import url("https://fonts.googleapis.com/css?family=Roboto:400");/* Set font of all elements to 'Roboto' */* {	font-family: 'Roboto', sans-serif;	font-weight: 400;}/* Remove outline of all elements on focus */*:focus {	outline: 0;}body {	background: #263238;  /* Set background color to #263238*/}h3 {	text-align: center;}/* Add styles to 'container' class */.container {	padding: 12px 24px 24px 24px;	margin: 48px 12px;	background: #E3F2FD;	border-radius: 4px;}/* Add styles to 'label' selector */label {	font-size: 0.85em;	margin-left: 12px;}/* Add styles to 'input' and 'textarea' selectors */input[type=text],input[type=email], textarea {    width: 100%;    padding: 12px;    border: 1px solid #ccc;    border-radius: 4px;    box-sizing: border-box;    margin-top: 6px;    margin-bottom: 16px;    resize: vertical;}/* Add styles to show 'focus' of selector */input[type=text]:focus,input[type=email]:focus, textarea:focus {	border: 1px solid green;}/* Add styles to the submit button */input[type=submit] {	background: #64B5F6;	margin: 0 auto;	outline: 0;	color: white;	border: 0;	padding: 12px 24px;	border-radius: 4px;	transition: all ease-in-out 0.1s;	position: relative;	display: inline-block;	text-align: center;}/* Add styles for 'focus' property */input[type=submit]:focus {	background: #A5D6A7;	color: whitesmoke;}/* Style 'hover' property */input[type=submit]:hover {	background: #2196F3;}/* Align items to center of the 'div' with the class 'center' */.center {	text-align: center;}

输出量 (Output)

更多信息: (More Information:)

Visit the on

访问上

翻译自:

引用自己创建的css样式表

转载地址:http://mlrwd.baihongyu.com/

你可能感兴趣的文章
BZOJ 4443: 小凸玩矩阵【二分图】
查看>>
苹果 OS X制作u盘启动盘
查看>>
Jquery便利对象
查看>>
MVC: Connection String
查看>>
idea常用设置汇总
查看>>
Node.SelectNodes
查看>>
Lambda表达式语法进一步巩固
查看>>
Vue基础安装(精华)
查看>>
Git 提交修改内容和查看被修改的内容
查看>>
PAT - 1008. 数组元素循环右移问题 (20)
查看>>
请求出现 Nginx 413 Request Entity Too Large错误的解决方法
查看>>
配置php_memcache访问网站的步骤
查看>>
hibernate的id生成策略
查看>>
树莓派3B+学习笔记:5、安装vim
查看>>
[Spfa][bfs] Jzoj P5781 秘密通道
查看>>
企业帐号进行IPA的打包、分发、下载安装的详细流程(转载)
查看>>
《项目架构那点儿事》——快速构建Junit用例
查看>>
{"errmsg":"invalid weapp pagepath hint: [IunP8a07243949]","errcode":40165}微信的坑
查看>>
DB2V9.5数据库使用pdf
查看>>
Java Bigdecimal使用
查看>>