分享
 
 
 

CSS使用大全,想学习或者了解CSS的网友一定不可错过

王朝html/css/js·作者佚名  2006-11-24
窄屏简体版  字體: |||超大  

有什么问题请到<a href='/bbs/forums.php?fid=21'><font color=red>论坛</font></a>中发表<br>

<!--# 特效来源:http://www.webjx.com/js -->

<!-- 把如下代码加入<body>区域中 -->

<style>

IMG {border:2px solid black}

BODY{

margin:0;

background:white;

font-family:verdana;

font-size:80%;

}

.bar{

background:#336699;

width:100%;

height:30px;

border-top:1px solid #99CCFF;

border-bottom:1px solid #000000;

}

.desbar{

background:#FFFFFF;

width:100%;

padding: 10px;

border-top:1px solid #CCCCCC;

border-bottom:1px solid #000000;

color:black;

font-size:8pt;

}

.title{

font-size:15pt;

color:white;

padding-left:10px;

}

PRE { margin:0}

a:link

{

text-decoration:none;

color:white

}

a:visited

{

text-decoration:none;

color:white

}

a:active

{

text-decoration:none;

color:white

}

a:hover

{

text-decoration:none;

color:yellow

}

SELECT { font-size:9pt; border:2px; }

</style>

<SCRIPT LANGUAGE="javascript">

var browserCapable = true;// Prevents errors on downlevel browsers

var startImage = "/img/200407101.gif"; // /workshop/graphics/

var endImage = "/img/200407102.gif";

var featuresHeader = "<B>Features:</B><BR>"

var sSinQut ="'";

var sRandomBarsOrientationText="";

function copy2Clipboard()

{

// Copy displayed code to user's clipboard.

var textRange = document.body.createTextRange();

textRange.moveToElementText(oCodeSpan);

textRange.execCommand("Copy");

}

function highlightText(whatToHighlight) {

var oRng = document.body.createTextRange();

oRng.moveToElementText(oCodePre);

oRng.execCommand("RemoveFormat");

var oHL = document.body.createTextRange();

oHL.moveToElementText(oCodePre);

oHL.findText(whatToHighlight);

oHL.execCommand("Bold");

}

function switchContent(obj) {

oContentHolder.innerHTML=obj.innerHTML;

oImg.src=startImage;

if (obj==filterSection){

changeFilter();

updateFilterCode();

}

else {

imgObjText.innerHTML = "<BR><b>First Page</b><BR><BR>Using the <B>apply</B> method prepares this SPAN element for content changes.";

changeTrans();

updateTransCode();

}

}

function getControlObject(controlName) {

var obj=null;

for (x=0; x < document.all(controlName).length; x++) {

objTemp = document.all(controlName,x);

if (objTemp.parentElement.isSource==null) {

obj=objTemp;

}

}

return(obj);

}

function disableControlObject(controlName) {

for (x=0; x < document.all(controlName).length; x++) {

document.all(controlName,x).disabled=true;

}

}

function enableControlObject(controlName) {

for (x=0; x < document.all(controlName).length; x++) {

document.all(controlName,x).disabled=false;

}

}

function changeFilter() {

var selectObject = getControlObject("oSelect");

var selectedValue = selectObject.options[selectObject.selectedIndex].value;

var transitionAsFilter = selectObject.options[selectObject.selectedIndex].TRANS;

imgObjText.innerHTML = "<BR>The image, dark red text, and sky blue background make up the content of the filtered SPAN.";

imgObj.style.backgroundColor='skyblue';

imgObj.style.color='darkred';

if (selectedValue != "empty") {

if (selectedValue.indexOf('AlphaImageLoader')!=-1) {

oControlsSpan.innerHTML = oAlphaImageLoaderControls.innerHTML;

alphaImageLoaderFilterChange();

}

else if (selectedValue.indexOf('Blur')!=-1) {

imgObj.style.backgroundColor='';

imgObjText.innerHTML = "<BR>The image, dark red text, and sky blue background make up the content of the filtered SPAN.";

oControlsSpan.innerHTML = oBlurControls.innerHTML;

blurFilterChange();

}

else if (selectedValue.indexOf('Alpha')!=-1) {

oControlsSpan.innerHTML = oAlphaControls.innerHTML;

alphaFilterChange();

}

else if (selectedValue.indexOf('Emboss')!=-1) {

oControlsSpan.innerHTML = "";

embossFilterChange();

}

else if (selectedValue.indexOf('Engrave')!=-1) {

oControlsSpan.innerHTML = "";

engraveFilterChange();

}

else if (selectedValue.indexOf('Pixelate')!=-1) {

oControlsSpan.innerHTML = oPixelateFilterControls.innerHTML;

pixelateFilterChange();

}

else if (selectedValue.indexOf('DropShadow')!=-1) {

imgObj.style.backgroundColor='';

imgObjText.innerHTML = "<BR>The image, dark red text, and sky blue background make up the content of the filtered SPAN.";

oControlsSpan.innerHTML = oDropShadowControls.innerHTML;

dropShadowFilterChange();

}

else if (selectedValue.indexOf('Chroma')!=-1) {

oControlsSpan.innerHTML = oChromaControls.innerHTML;

chromaFilterChange();

}

else if (selectedValue.indexOf('BasicImage')!=-1) {

oControlsSpan.innerHTML = oBasicImageControls.innerHTML;

basicImageFilterChange();

}

else {

imgObj.style.filter=selectedValue;

oControlsSpan.innerHTML = '';

}

if (oControlsSpan.innerHTML!='') {

oControlsSpan.innerHTML = featuresHeader + oControlsSpan.innerHTML;

}

if (transitionAsFilter == "TRUE") {

oControlsSpan.innerHTML = oControlsSpan.innerHTML + oGlobalControls.innerHTML;

progressChange();

}

}

else {

imgObj.style.filter='';

oControlsSpan.innerHTML = featuresHeader + 'No filter is currently selected.';

}

updateFilterCode();

}

function updateFilterCode() {

oCodePre.innerText=imgObj.outerHTML;

}

function alphaFilterChange(){

var cmd;

var controlObject = getControlObject("styleList");

var style = controlObject.options[controlObject.selectedIndex].value;

controlObject = getControlObject("opacityList");

var opacity = controlObject.options[controlObject.selectedIndex].value;

cmd = "imgObj.style.filter='progid:DXImageTransform.Microsoft.Alpha( " ;

cmd = cmd + "style=" + style + ",opacity=" + opacity ;

if (style!=0){

controlObject = getControlObject("finishOpacityList");

enableControlObject("finishOpacityList");

var finishOpacity = controlObject.options[controlObject.selectedIndex].value;

cmd = cmd + ",finishOpacity=" + finishOpacity ;

if (style==1){

controlObject = getControlObject("startXList");

enableControlObject("startXList");

var startX = controlObject.options[controlObject.selectedIndex].value;

controlObject = getControlObject("finishXList");

enableControlObject("finishXList");

var finishX = controlObject.options[controlObject.selectedIndex].value;

controlObject = getControlObject("startYList");

enableControlObject("startYList");

var startY = controlObject.options[controlObject.selectedIndex].value;

controlObject = getControlObject("finishYList");

enableControlObject("finishYList");

var finishY = controlObject.options[controlObject.selectedIndex].value;

cmd = cmd + ",startX=" + startX + ",finishX=" + finishX ;

cmd = cmd + ",startY=" + startY + ",finishY=" + finishY;

}

else{

disableControlObject("startXList");

disableControlObject("finishXList");

disableControlObject("startYList");

disableControlObject("finishYList");

}

}

else{

disableControlObject("finishOpacityList");

disableControlObject("startXList");

disableControlObject("finishXList");

disableControlObject("startYList");

disableControlObject("finishYList");

}

cmd = cmd + ")'";

eval(cmd);

updateFilterCode();

highlightText(cmd);

}

function alphaImageLoaderFilterChange(){

var cmd;

var controlObject = getControlObject("srcList");

var src = controlObject.options[controlObject.selectedIndex].value;

controlObject = getControlObject("sizingMethodList");

var sizingmethod = controlObject.options[controlObject.selectedIndex].value;

cmd = "imgObj.style.filter='progid:DXImageTransform.Microsoft.AlphaImageLoader( " ;

cmd = cmd + "src=" + src + ", sizingmethod=" + sizingmethod + ")'";

eval(cmd);

updateFilterCode();

highlightText(cmd);

}

function basicImageFilterChange(){

var cmd;

var controlObject = getControlObject("rotationList");

var rotation = controlObject.options[controlObject.selectedIndex].value;

controlObject = getControlObject("mirrorSwitch");

controlObject.checked==true ? mirror = 1 : mirror = 0

controlObject = getControlObject("invertSwitch");

controlObject.checked==true ? invert = 1 : invert = 0

controlObject = getControlObject("xraySwitch");

controlObject.checked==true ? xray = 1 : xray = 0

control

[1] [2] [3] [4] [5] [6] 下一页

 
 
 
免责声明:本文为网络用户发布,其观点仅代表作者个人观点,与本站无关,本站仅提供信息存储服务。文中陈述内容未经本站证实,其真实性、完整性、及时性本站不作任何保证或承诺,请读者仅作参考,并请自行核实相关内容。
2023年上半年GDP全球前十五强
 百态   2023-10-24
美众议院议长启动对拜登的弹劾调查
 百态   2023-09-13
上海、济南、武汉等多地出现不明坠落物
 探索   2023-09-06
印度或要将国名改为“巴拉特”
 百态   2023-09-06
男子为女友送行,买票不登机被捕
 百态   2023-08-20
手机地震预警功能怎么开?
 干货   2023-08-06
女子4年卖2套房花700多万做美容:不但没变美脸,面部还出现变形
 百态   2023-08-04
住户一楼被水淹 还冲来8头猪
 百态   2023-07-31
女子体内爬出大量瓜子状活虫
 百态   2023-07-25
地球连续35年收到神秘规律性信号,网友:不要回答!
 探索   2023-07-21
全球镓价格本周大涨27%
 探索   2023-07-09
钱都流向了那些不缺钱的人,苦都留给了能吃苦的人
 探索   2023-07-02
倩女手游刀客魅者强控制(强混乱强眩晕强睡眠)和对应控制抗性的关系
 百态   2020-08-20
美国5月9日最新疫情:美国确诊人数突破131万
 百态   2020-05-09
荷兰政府宣布将集体辞职
 干货   2020-04-30
倩女幽魂手游师徒任务情义春秋猜成语答案逍遥观:鹏程万里
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案神机营:射石饮羽
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案昆仑山:拔刀相助
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案天工阁:鬼斧神工
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案丝路古道:单枪匹马
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案镇郊荒野:与虎谋皮
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案镇郊荒野:李代桃僵
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案镇郊荒野:指鹿为马
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案金陵:小鸟依人
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案金陵:千金买邻
 干货   2019-11-12
 
推荐阅读
 
 
 
>>返回首頁<<
 
靜靜地坐在廢墟上,四周的荒凉一望無際,忽然覺得,淒涼也很美
© 2005- 王朝網路 版權所有