HTML笔记

官方文档:w3school.com.cn
字体大小font-size
标签<a href="…“target=”…"
href:指定资源访问的url1
target:指定在何处打开资源链接
_self:默认值,在当前页面打开
_blank:在空白页面打开
视频标签:
src:规定视频的url,controls:显示播放控件,width:播放器宽度,height:播放器高度
音频标签:
src:规定音频url,controls:显示播放控件
段落标签

,文本加粗标签:

换行
text-indent:35px段落首行缩进
line-height:25px行高
text-align:right;文字对齐方式

表格标签

div的学习全称division划分区域
盒子模型
内容区域(content),内边框区域(padding),边框区域(border),外边框区域(margin)

span
font-size:20px:字体大小
background-image:url(图片);
background-repeat:no-repeat;
强国 广告斜体样式

元素的定位:position

.box1 i{

display:block;display:inline行内元素默认
width37
height24
background-color:
font-style:normal
文字居中text-align:center;
line-height:24px
position:absolute
透明设置:opacity:0.5?
背景色:background-color:rgb(255.0.0);
定位:初始值position:static
1.相对定位:position:relative; left:100px; top:100px相对于原来的位置
2.绝对定位:position:absolute;相对于已经定位的父元素进行定位就是父级别已经经过了position:relative;定位
3.固定定位:position:fixed;不随着屏幕的移动而移动
3.23
无序列表
.fix{
border-radius:5px;圆角边框

}
.fix ul al{
list-style:none;无序列表前面的点隐藏
}
.fix ul{
margin:0;
padding:0;无序列表的点占的空间清除
}
}
display:none;消失
鼠标放上去出现
.no1:hover.tan1{
display:block;
}

字体下滑线消失:text-decoration:none;
h5鼠标放上去,字体变红如何去写
可以使用CSS来实现:

a:hover {
    color: red;
}

div重叠
div.bbox>.imgbox*10
.bbox,.imgbox{
width:1240
height:580
b
}
圆角边框:border-redius:20px;
CSS3高级应用
过渡
鼠标移动上方有变化
.box:hover
{
background-color:red;
过渡:transition
属性;transition-property:background-color
持续时间:transition-duration:4s;
推迟:transition-delay:2s;可选
transition-timing~function:ease-in-out:
简写:transition:all 4s ease-in-out;
}
-webkit-transform:scale(2)
谷歌私有 缩放 大小
-ms-IE浏览器
放缩中心点;-webik-transform-origin:left top;(0% 100%)
transition:all 2s;
overflow:hidden;超出部分隐藏;
.box:hover{
-webkit-transform:rotate(30deg);
}

js引入方式
内部脚本

外部脚本

alert(“hello Javascript”)
js基础语法
alert(“jsp”)提示框
输出语句
window.alert(“hellojava”);浏览器弹出警告框
document.write(“holleJava”);写入HTML,在浏览器展示
console.log(“hollejava”);写入浏览器控制台
变量:全局变量ver,局部变量let,常量const,不能改变。
var x=1;
x=“张三”
特点:作用域比较大,全局变量,可以重复定义
===不会进行类型转换
parseInt类型转换-其他类型为数字
js函数
js函数通过function关键字进行定义,语法为:
function functionName(参数1,参数2){
要执行的代码块
}
function add(a,b){
return a+b;
}
定义函数:var add=function(a,b){
a+b;
}
函数调用:var result=add(10,20,30,40);
alert(result);//30
js对象
Array,String,JSON,BOM,DOM
Array定义数值
var 变量名=new Array(元素列表);
var 变量名=[元素列表];
访问:

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 1
    评论
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

想要入门的程序猿

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值