导航:首页 > 万维百科 > 网页设计页面背景色怎么做

网页设计页面背景色怎么做

发布时间:2020-11-16 12:36:04

1、制作网页如何改变背景颜色

<head>
<title></title>
<style type="text/css">
body{background-color:#000;}
</style>
</head>
这是整体改变背景颜色,单独改某个区域的话,用bgcolor这个

2、网页制作中使整个网页背景为一个颜色或一张图片的代码怎么写?

设置背景色<body style="background:#CC9999">
</body>

设置背景图片<body style="background-image:url(图片地址)">
</body>

3、网页设计表格背景颜色

可以用background

body
  { 
  background: #00FF00 url(bgimage.gif) no-repeat fixed top;
  }

定义和用法

background 简写属性在一个声明中设置所有的背景属性。

4、怎么设计css网页背景颜色过渡?

CSS实现渐变背景效果兼容主流浏览器
IE浏览器下渐变背景的使用需要使用IE的渐变滤镜filter
对于Firefox浏览器下(Firefox 3.6+)渐变背景的实现需使用CSS3渐变属性 为-moz-linear-gradient属性
对于webkit核心的浏览器,如Chrome/Safari浏览器下渐变背景的实现也是使用CSS3 渐变方法为-webkit-gradient
代码如下:
.gradient{
width:300px;
height:150px;
filter:alpha(opacity=100 finishopacity=50 style=1 startx=0,starty=0,finishx=0,finishy=150) progid:DXImageTransform.Microsoft.gradient(startcolorstr=red,endcolorstr=blue,gradientType=0);/*IE*/
-ms-filter:alpha(opacity=100 finishopacity=50 style=1 startx=0,starty=0,finishx=0,finishy=150) progid:DXImageTransform.Microsoft.gradient(startcolorstr=red,endcolorstr=blue,gradientType=0);/*IE8*/
background:red; /* 一些不支持背景渐变的浏览器 */
background:-moz-linear-gradient(top, red, rgba(0, 0, 255, 0.5)); /*Firefox*/
background:-webkit-gradient(linear, 0 0, 0 bottom, from(#ff0000), to(rgba(0, 0, 255, 0.5))); /*Chrome/Safari*/
}
<div class="gradient"></div>

5、如何设置网页背景颜色

第一步, 在桌面上点击鼠标右键,依次点击“属性”、“外观”、“高级”按钮。

第二步, 在打开的“高级”对话框中,在“项目”下拉列表里选择“窗口”。

第三步, 再打开右边对应的“颜色”列表,选择其中的“其他”一项,在打开的对话框里,把“色调”的参数设置为85,把“饱和度”参数设置为90,把“亮度”参数设置为205。再点击“确定”退出设置。

第四步,打开ie浏览器,选择“工具”栏中的“internet选项”,点击“辅助功能”按钮,在“不使用网页中指定的颜色”前打钩。
全部步骤完成后,网页、文件夹、文本文档里的背景颜色都变成了绿色。其中,色调、饱和度和亮度的参数值,还可以根据个人的喜好稍作修改,让自己用电脑的候最舒服。

6、html 网页制作 如何设置网页背景色

首先打开电脑上自带的记事本程序,然后输入html网页基本结构语句。<html><body></body></html>

由于css样式必须在标签<head></head>之间,因此我们点击<html>后面,输入<head></head>标签。

在head标签之间输入样式标签<style></style>,然后定义一些属性,例如

<style type="text/css">

body {background-color: yellow} 定义网页背景色为黄色;

h1 {background-color: #00ff00} 定义h1标签背景色为#00ff00;

h2 {background-color: transparent} 定义h2标签背景色为透明;

p {background-color: rgb(250,0,255)} 定义p标签背景色为rgb值;

p.no2 {background-color: gray; padding: 20px;} 这个定义class属性为no2的p标签背景色为灰色,并且边距为20px;

</style>

然后点击body标签后面输入正文标签内容,例如

<h1>这是KING</h1>

<h2>这是KING</h2>

<p>这是KING</p>

<p class="no2">这个KING设置20内边距。</p>

点击记事本菜单中的文件,选择另存为,把内容保存为html网页格式。双击打开预览效果。

我们可以发现代码中两个同样的<p>标签显示的css样式却不同,区别就在于样式中定义的p.no2,这就是正文代码中class="no2"的优势所在,可以定义个性风格。

7、网页设计中,怎么用CSS做出磨砂的背景效果?

代码:透明背景(带磨砂玻璃效果)注:在粘贴到空白模板前一定先打个空格。

<STYLE type=text/css>

.bodytop{background:#transparent}

.banner{ background:#transparent}

.menu{ background:#transparent}

.bodyBg {background:#transparent;filter:progid:DXImageTransform.Microsoft.gradient(GradientType ='1',enabled='true',startColorstr=#AAFFFFFF, endColorstr=#AAFFFFFF);}

.zone{ background:#transparent}

.bodyBottom{background:#transparent}

.feeds .up{background:#transparent}

.feeds .down{background:#transparent }

.feeds .function{background:#transparent}

.feeds .page{background:#transparent}

.aList .sysHand .up{background:#transparent}

.aList .sysHand .down{background:#transparent}

.gbook .sysHand .up{background:#transparent}

.gbook .sysHand .down{background:#transparent}

.gbook .title{display:none;}

.logo{display:none;}

.gbook .page{background:#transparent }

.gbook .login{background:#transparent}

.box_1{background:#transparent}

.box_2{background:#transparent}

.calendar{background:#transparent}

.calendar .mid{background:#transparent}

.calendar .top{background:#transparent}

.calendar .title{background:#transparent}

.calendar .bold td{background:#transparent}

.calendar .bottom{background:#transparent}

.callboard .mid{background:#transparent}

.callboard .mid img{background:#transparent}

.callboard .front{background:#transparent}

.callboard .back{background:#transparent}

.callboard table{background:#transparent}

.callboard .up{background:#transparent}

.callboard .down{background:#transparent }

.sysBr{background:#transparent}

.sysBr210{background:#transparent}

.label{background:#transparent}

.label .mid{background:#transparent}

.label .top{background:#transparent}

.label .bottom{background:#transparent}

.photo{background:#transparent}

.photo .mid{background:#transparent}

.photo .image{background:#transparent}

.photo .top{background:#transparent}

.photo .bottom{background:#transparent}

.links{background:#transparent}

.links .up{background:#transparent}

.links .down{background:#transparent }

.links .mid{background:#transparent}

body{background:url("
http://s11.sinaimg.cn/orignal/439175a380fda7635072a
") repeat fixed!important;}

.add{background:#transparent}

.add .ico{background:#transparent}

</STYLE>

8、制作网页如何改变背景颜色?

打开Adobe Dreamweaver,新建一个HTML网页文件.

网页的一般结构,首先是DOCTYPE声明,然后是头部标签<head>...</head>,文档的主体<body>..</body>标签,我们需要设置网页背景,直接设置<body>标签的背景就行了。

点击右边的所有规则,新建一条规则,在弹出的界面,选择器类型为标签选择器,选择器名称为body,然后点击确认。

在CSS规则里面选择背景,在“background-color”里面选择一种颜色作为网页背景色,然后点击确认。

然后点击在浏览器调试,查看网页背景,详细代码如下:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">

<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<title>无标题文档</title>

<style type="text/css">

body {

background-color: #FC6;

}

</style>

</head>

<body>

</body>

</html>

网页不仅仅可以用颜色作为背景,还可以用图片作为网页背景,打开刚才新建的规则,继续选择背景,“background-image”选项后面有浏览按钮,将作为背景的图片选择好,然后点击确认。

然后在调试网页,查看网页的背景,图片已经作为网页的背景颜色了。代码如下:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">

<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<title>无标题文档</title>

<style type="text/css">

body {

background-image: url(10/38.png);

}

</style>

</head>

<body>

</body>

</html>

9、Dreamweaver制作网页中设置页面的大小及页面背景色

1、直接打开Dreamweaver软件。

2、点击下面属性面板中的页面属性。

3、弹出对话框后可以自定义背景色,也可以添加背景图片,根据需要制作的宽度来定义其他表单即可。

与网页设计页面背景色怎么做相关的知识