上传头像
2017-07-06 11:43
281 查看
简单的上传头像静态页面
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>tupian</title>
<style>
.white_content {
position: absolute;
display:none;
top: 25%;
left: 35%;
width: 632px;
height: 494px;
padding: 20px;
border: 1px solid #adacac;
background-color: white;
z-index:1002;
overflow: auto;
}
.sj_con {
padding: 0px;
height: 460px;
width: 600px;
margin-top: 10px;
margin-right: 0px;
margin-bottom: 0px;
margin-left: 15px;
}
.sctp{width:500px; height:40px;}
.uploadfile{width:132px;}
.input-file{display: inline-block;width: 130px;font-size: 18px;line-height: 37px;height: 40px;text-align: center; overflow: hidden;position: relative;background: #2FA8E6;color: #fff; transition:background .3s;-webkit-transition:background .3s}/*自定义外框样式*/
.input-file input{opacity: 0;filter:alpha(opacity=0);font-size: 100px;position: absolute;top: 0;right: 0} /*隐藏默认控件样式*/
.scgs {
font-size: 14px;
line-height: 40px;
color: #666;
text-align: left;
padding: 0px;
height: 43px;
width: 500px;
margin-top: 10px;
margin-right: 0px;
margin-bottom: 0px;
margin-left: 20px;
}
.ig {
padding: 0px;
height: 250px;
width: 600px;
margin-top: 20px;
margin-right: 0px;
margin-bottom: 0px;
margin-left: 0px;
border-bottom-width: 1px;
border-bottom-style: solid;
border-bottom-color: #CCC;
}
.txdx {
margin: 0px;
padding: 0px;
float: left;
height: 200px;
width: 200px;
border: 1px solid #FF0;
}
.txdx1 {
padding: 0px;
float: left;
height: 150px;
width: 150px;
border: 1px solid #FF0;
margin-top: 0px;
margin-right: 0px;
margin-bottom: 0px;
margin-left: 30px;
}
.seltt {
height: 50px;
width: 214px;
margin-top:25px;
float:left;
padding: 0px;
margin-right: 0px;
margin-bottom: 10;
margin-left: 380px;
}
.lfbt {
font-size: 14px;
line-height: 25px;
color: #FFF;
background-color: #009ddc;
text-align: center;
float: left;
height: 25px;
width: 100px;
}
.lfbt a {
color: #FFF;
text-decoration: none;
}
</style>
</head>
<body>
<p>示例弹出层:<a href = "javascript:void(0)" onclick = "document.getElementById('light').style.display='block';document.getElementById('fade').style.display='block'">请点这里</a></p>
<div id="light" class="white_content">
<div class="sj_con">
<div class="sctp">
<form action=" " enctype="multipart/form-data" method="post" class="uploadfile"><label class="input-file"><input title="浏览文件" type="file" name="file">上传图片</label><input type="hidden" name="id" value="104"></form>
</div>
<div class="scgs">仅支持JPG,PNG,GIF格式,文件小于5M</div>
<div class="ig">
<div class="txdx"></div>
<div class="txdx1"></div>
</div>
<div class="seltt">
<div class="lfbt"><a href = "javascript:void(0)" onclick = "document.getElementById('light').style.display='none';document.getElementById('fade').style.display='none'">提交</a></div>
<div class="lfbt" style="float:right;"><a href = "javascript:void(0)" onclick = "document.getElementById('light').style.display='none';document.getElementById('fade').style.display='none'">取消</a></div>
</div>
</div>
</div>
<div id="fade" class="black_overlay"></div>
</body>
</html>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>tupian</title>
<style>
.white_content {
position: absolute;
display:none;
top: 25%;
left: 35%;
width: 632px;
height: 494px;
padding: 20px;
border: 1px solid #adacac;
background-color: white;
z-index:1002;
overflow: auto;
}
.sj_con {
padding: 0px;
height: 460px;
width: 600px;
margin-top: 10px;
margin-right: 0px;
margin-bottom: 0px;
margin-left: 15px;
}
.sctp{width:500px; height:40px;}
.uploadfile{width:132px;}
.input-file{display: inline-block;width: 130px;font-size: 18px;line-height: 37px;height: 40px;text-align: center; overflow: hidden;position: relative;background: #2FA8E6;color: #fff; transition:background .3s;-webkit-transition:background .3s}/*自定义外框样式*/
.input-file input{opacity: 0;filter:alpha(opacity=0);font-size: 100px;position: absolute;top: 0;right: 0} /*隐藏默认控件样式*/
.scgs {
font-size: 14px;
line-height: 40px;
color: #666;
text-align: left;
padding: 0px;
height: 43px;
width: 500px;
margin-top: 10px;
margin-right: 0px;
margin-bottom: 0px;
margin-left: 20px;
}
.ig {
padding: 0px;
height: 250px;
width: 600px;
margin-top: 20px;
margin-right: 0px;
margin-bottom: 0px;
margin-left: 0px;
border-bottom-width: 1px;
border-bottom-style: solid;
border-bottom-color: #CCC;
}
.txdx {
margin: 0px;
padding: 0px;
float: left;
height: 200px;
width: 200px;
border: 1px solid #FF0;
}
.txdx1 {
padding: 0px;
float: left;
height: 150px;
width: 150px;
border: 1px solid #FF0;
margin-top: 0px;
margin-right: 0px;
margin-bottom: 0px;
margin-left: 30px;
}
.seltt {
height: 50px;
width: 214px;
margin-top:25px;
float:left;
padding: 0px;
margin-right: 0px;
margin-bottom: 10;
margin-left: 380px;
}
.lfbt {
font-size: 14px;
line-height: 25px;
color: #FFF;
background-color: #009ddc;
text-align: center;
float: left;
height: 25px;
width: 100px;
}
.lfbt a {
color: #FFF;
text-decoration: none;
}
</style>
</head>
<body>
<p>示例弹出层:<a href = "javascript:void(0)" onclick = "document.getElementById('light').style.display='block';document.getElementById('fade').style.display='block'">请点这里</a></p>
<div id="light" class="white_content">
<div class="sj_con">
<div class="sctp">
<form action=" " enctype="multipart/form-data" method="post" class="uploadfile"><label class="input-file"><input title="浏览文件" type="file" name="file">上传图片</label><input type="hidden" name="id" value="104"></form>
</div>
<div class="scgs">仅支持JPG,PNG,GIF格式,文件小于5M</div>
<div class="ig">
<div class="txdx"></div>
<div class="txdx1"></div>
</div>
<div class="seltt">
<div class="lfbt"><a href = "javascript:void(0)" onclick = "document.getElementById('light').style.display='none';document.getElementById('fade').style.display='none'">提交</a></div>
<div class="lfbt" style="float:right;"><a href = "javascript:void(0)" onclick = "document.getElementById('light').style.display='none';document.getElementById('fade').style.display='none'">取消</a></div>
</div>
</div>
</div>
<div id="fade" class="black_overlay"></div>
</body>
</html>
相关文章推荐
- discuz 上传头像时 提示 目录不可写 Can not write to the data/tmp folder!
- Android上传头像代码,相机,相册,裁剪
- android开发之用户头像上传
- Django1.10 扩展User属性增加头像上传功能
- iOS开发类似微信上传头像小操作Demo
- [置顶] Android 上传文件,头像。流形式
- 使用Flash结合PHP实现头像的无刷新上传与裁剪
- android裁剪头像上传
- 结合sae,thinkphp完成头像的更改与上传
- iOS 相机调用相册打开及图片头像的上传到服务器详解
- 上传头像 调用相机拍照 ,及简单的调用相册的照片来上传头像
- Android上传头像,图片剪裁,压缩图片
- jQuery实现模拟flash头像裁切上传功能示例
- 头像上传到数据库再查询到页面
- ajax上传图片加裁剪作为头像
- js会员头像上传拖动处理头像类
- Swift 头像上传(4)Alamofire上传图片到服务器
- [Bootstrap-插件使用]Jcrop+fileinput组合实现头像上传功能实例代码
- mvc4 截取上传图片做头像,自动生成不同小尺寸缩略图 (地址)
- 扩展AD 用户上传头像