<!-- End .list --><!-- <div class="bottom"></div> --><!-- End .hotapplist -->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="gb2312" >
<head>
<meta http-equiv="content-type" content="text/html; charset=gb2312" />
<meta name="author" content="Smiling Dolphin" />
<meta name="keywords" content="design, css, cascading, style, sheets, xhtml, graphic design, w3c, web standards, visual, display, java, javascript, c++, php, jsp, asp, py, pl" />
<meta name="description" content="my favorites language." />
<meta name="robots" content="all" />
<title>Dolphin Document</title>
<style type="text/css" title="currentStyle" media="screen">
body,p{
margin:0px;
padding:0px;
}
</style>
</head>
<body>
<input type="button" value="显示Alert" onclick="alert('我改写了Alert显示的样式')" />
<textarea>这里显示文章</textarea>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<p>abc</p>
<script language="javascript" type="text/javascript">
window.alert = function(txt)
{
var shield = document.createElement("DIV");
shield.id = "shield";
shield.style.position = "absolute";
shield.style.left = "0px";
shield.style.top = "0px";
shield.style.width = "100%";
shield.style.height = document.body.scrollHeight+"px";
shield.style.background = "#333";
shield.style.textAlign = "center";
shield.style.zIndex = "10000";
shield.style.filter = "alpha(opacity=0)";
var alertFram = document.createElement("DIV");
alertFram.id="alertFram";
alertFram.style.position = "absolute";
alertFram.style.left = "50%";
alertFram.style.top = "50%";
alertFram.style.marginLeft = "-225px";
alertFram.style.marginTop = "-75px";
alertFram.style.width = "450px";
alertFram.style.height = "150px";
alertFram.style.background = "#ccc";
alertFram.style.textAlign = "center";
alertFram.style.lineHeight = "150px";
alertFram.style.zIndex = "10001";
strHtml = "<ul style=\"list-style:none;margin:0px;padding:0px;width:100%\">\n";
strHtml += " <li style=\"background:#DD828D;text-align:left;padding-left:20px;font-size:14px;font-weight:bold;height:25px;line-height:25px;border:1px solid #F9CADE;\">[系统提示]</li>\n";
strHtml += " <li style=\"background:#fff;text-align:center;font-size:12px;height:120px;line-height:120px;border-left:1px solid #F9CADE;border-right:1px solid #F9CADE;\">"+txt+"</li>\n";
strHtml += " <li style=\"background:#FDEEF4;text-align:center;font-weight:bold;height:25px;line-height:25px; border:1px solid #F9CADE;\"><input type=\"button\" value=\"确 定\" onclick=\"doOk()\" /></li>\n";
strHtml += "</ul>\n";
alertFram.innerHTML = strHtml;
document.body.appendChild(alertFram);
document.body.appendChild(shield);
var c = 0;
this.doAlpha = function(){
if (c++ > 20){clearInterval(ad);return 0;}
shield.style.filter = "alpha(opacity="+c+");";
}
var ad = setInterval("doAlpha()",5);
this.doOk = function(){
alertFram.style.display = "none";
shield.style.display = "none";
}
alertFram.focus();
document.body.onselectstart = function(){return false;};
}
</script>
</body>
</html>
分享到:
相关推荐
可以直接调用,操作方便,调用代码如下: jConfirm('Can you confirm this,<span am red.</span>?', 'Confirmation Dialog', function(r) { });
js alert confirm样式弹出框是一款根据alert confirm优化样式的确认对话框代码。
alert和confirm弹出框样式美化,可自定义颜色和样式,无须调用浏览器自带弹框。
代码如下: window.alert = function(str) { var shield = document.createElement(“DIV”); shield.id = “shield”; shield.style.position = “absolute”; shield.style.left = “0px”; shield.style.top = “0...
下面小编就为大家带来一篇修改js confirm alert 提示框文字的简单实例。小编觉得挺不错的,现在就分享给大家,也给大家做个参考。一起跟随小编过来看看吧
自定义样式的alert,confirm窗口,可连续弹窗
引导警报框 一个不错的引导程序样式警报和确认框。 覆盖默认的 JS 警报和确认框
组件名称:ymPrompt消息提示组件 2.0 =======================================...12、程序(js)与样式(css)的完全分离,取消了1.0中自动加载css的功能,用户可根据需要加载对应css样式表单,降低了对样式配置的复杂度。
npm i react - native - alert - modalize 对等依赖 重要的! 你需要安装它们 "react-native-modalize" : ">= 1.2.3" , "react-native-gesture-handler" : ">= 1.5.2" , "react-native-material-ripple" : ">= ...
SweetAlert可以替代Javascript原生的alert和confirm等函数呈现的弹出提示框,它将提示框进行了美化,并且允许自定义,支持设置提示框标题、提示类型、内容展示图片、确认取消按钮文本、点击后回调函数等。
alert和comfirm,里面有源码,代码复用性很高,如果你不满意我的,也可以适当的修改我的,想用的话,直接下载即可
alert("提交修改后的数据:"+mo); //document.location.reload(); } }, // 删除操作 delAction : { button : BaseJs.$('delete'), // 删除url 可用函数返回动态url url : function() { return '...
1.修改标题样式。把jquery ui的标题样式放上去。支持换肤。 2.修改按钮样式,换成jqueryui的button按钮样式。 3.将模式化窗口的背景换成了jqueryui的模式化背景。 代码: //首先要引入jquery,以及ui的包和皮肤的...
* 自定义javascript常用基础库 author zhang_jhai 创建时间 2010/04/10 最后修改时间 2010/05/03 * version 2.0 */ // Base库基础类 BaseJs = function() { // 判断浏览器类型 userAgent = navigator....
13.4.1 使用alert()语句 382 13.4.2 使用write()语句 382 13.4.3 抛出自定义异常消息 383 第4篇 JavaScript特效应用 第14章 JavaScript网页特效 387 14.1 文字特效 387 14.1.1 文字向上不间断无缝滚动 387 14.1.2 ...
大家应该还记得JavaScript行内样式怎么写吧?(看来我是废话了!) 在前端开发过程中,有时我们需要判断浏览器的内核前缀,对不同的浏览器做出不同的处理,因此我们可以这么做。 alert(element.style....
14.11.2 JavaScript如何操作样式表 14.11.3 style对象 14.11.4 className属性 14.11.5 下拉菜单和提示框 14.12 应知应会 练习 第15章 W3C DOM与JavaScript 15.1 W3C DOM ...
有兴趣可以修改样式表文件定义新的皮肤。 4、提供四种消息类型。分别为消息提示、成功信息、错误信息、询问信息。 5、弹出消息框时屏蔽页面其它元素的操作,自动隐藏页面select及iframe下select(无限级select隐藏)...
在做B/S开发的时候,通常会遇到很多的客户与服务器的交流,而浏览器自带的弹出工具条是不能修改样式的,用JS模拟一个华丽的工具条逐渐成为这一形式的主流,而这些工具条平时的开发当中重复量很大。JTooltips插件致力...
美化了原有的弹窗,做成类似凡客诚品的alert,confirm弹出窗样式,下载后修改即可使用。