html div bgcolor,HTML body bgcolor transparent
问题
I have this HTML
style="margin:0px;padding:0px;"
Here i have set bgcolor="#FFFFFF" but i want it to be transparent how to do it ?
回答1:
HTML provides no means to specify a transparent background (and the means it has to specify backgrounds of any kind are obsolete and should not be used). You can do this in CSS.
body {
background-color: transparent;
}
This will make the background of the element visible.
There is no way to make the browser window transparent.
回答2:
With inline-styling you can achieve this with:
But a better option is to put the following code:
body { background-color:transparent; }
in a CSS file which you link to in the
section of the page like so:
回答3:
background-color: transparent;
Update
However, you HAVE NO WAY to make the browser window transparent. So, even if you use the code above, your background will still be white.
回答4:
You need to use CSS instead of HTML attributes to set transparent background:
Preferably you should have a style sheet for the page where you put the styles instead of putting styles in the HTML elements.
Note: To have an iframe with a transparent background (which is the only way that a transparent background on a page can be used) you need to add the allowtransparency attribute to the iframe tag for it to work in IE:
回答5:
body {
background-color: rgba(255, 255, 255, 0.5)
};
last value is alpha - it will set transparency values between 0 and 1; 0 transparent;
来源:https://stackoverflow.com/questions/23564182/html-body-bgcolor-transparent
html div bgcolor,HTML body bgcolor transparent相关推荐
- BGColor.jsp
<HTML><HEAD> <TITLE>Color Testing</TITLE></HEAD> <!--html注释--> & ...
- day01【HTML基础】HTML表单【重点】、表单控件、水平线标签、段落和换行标签、超链接标签、图像标签、列表标签、div和span标签、 转义(实体)字符、 基本表格、合并表格
HTML 一 HTML概述 超文本标记语言(Hyper Text Markup Language) 作用:搭建基础网页 超文本:具有普通文本的特性,同时还可以加入图片.视频.超链接等等. 标记:即标签 ...
- Js+Dhtml:WEB程序员简易开发工具包(预先体验版)
作者:lshdic http://blog.csdn.net/lshdic/ <HTML> <HEAD> <META http-equiv='Content-Type ...
- [转]JavaScript代码收集
来自<转贴自大雨仔的js收藏>: //打开模式对话框 function doSelectUser(txtId) { strFeatures="dialogWidth=500px; ...
- 测试MM32 MicroPython测试电路板的基本功能
简 介: 对于来自于逐飞的MM32 MicroPython模块进行补充测试.总结了现在一些缺少的功能. 关键词: MicroPython,MM32,逐飞,灵动单片机 #mermaid-svg-JjPS ...
- HTML IFRAME 用法小总结
iframe是框架的一种形式,也比较常用到,下面是对其在平时常用到属性的总结 Iframe用法,下面是一个常规的列子 <iframe border=2 frameborder=0 width=5 ...
- 总结网站调用Flash的几种方法【转】
一.Adobe 提供的方法 <object width="200" height="200" classid="clsid:D27CDB6E-A ...
- javascript技巧收集(200多个)---转
1.文本框焦点问题 onBlur:当失去输入焦点后产生该事件 onFocus:当输入获得焦点后,产生该文件 Onchange:当文字值改变时,产生该事件 Onselect:当文字加亮后,产生该文件 & ...
- Javascript 常用功能收集-blogjava
//打开模式对话框 function doSelectUser(txtId) { strFeatures="dialogWidth=500px;dialogHeight=36 ...
最新文章
- 一文详解SVM的Soft-Margin机制
- Toad for Oracle9.7中导入数据库以后,数据有中文乱码:
- 苹果WWDC2021终极剧透!新款Macbook Pro外观大改 iOS 15将发布
- Enterprise Library 4.1学习笔记3----安全应用程序块
- think php getfield,thinkPHP数据查询常用方法总结【select,find,getField,query】
- 话里话外:谁才是流程的主人
- FFmpeg的H.264解码器源代码简单分析:宏块解码(Decode)部分-帧间宏块(Inter)
- 论文答辩相关PPT:论文答辩模板及其它
- 照片识别出错_8款文字识别工具,只要拍个照,文字马上可编辑
- 语音增强算法研究系列笔记 - 语音噪声分类及特点
- iOS 开发常见崩溃分析
- 系统无法以在此计算机上安装,windows无法完成安装若要在此计算机上安装怎么办...
- Java中类的修饰符有哪些?
- Ubunt14.04搭建opengrok环境
- c语言小车程序,循迹小车的C语言程序(带注释)
- 【Android 仿微信通讯录 导航分组列表-上】使用ItemDecoration为RecyclerView打造带悬停头部的分组列表
- 面试刷题LeetCode经典100道
- 初中计算机科学生情况,初中计算机科学与技术的现代化运用探究
- [Java]Maven学习笔记(尚硅谷2022)
- 真c++ 从二叉树到红黑树(4)之二叉平衡搜索树AVL