如何实现IE右下脚的窗口? 就是一个层吗 ?不用window.open 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 看不到图下面是在浏览器右下角弹出提示,延时隐藏var oPopup = window.createPopup(); var popTop=50; function popmsg(qr_whdanmsg,whdanmsg,mimamsg){ var winstr=" <table style=\"border: 1 solid #FFA6CA\" width=\"241\" height=\"172\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\">"; winstr+=" <tr>"; winstr+=" <td height=\"25\"> </td>"; winstr+=" </tr>"; winstr+=" <tr>"; winstr+=" <td height=\"25\" align=\"center\" valign=\"top\" style=\"font-size:12px; color: red; face: Tahoma ;\" >"+whdanmsg+" </td>"; winstr+=" </tr>"; winstr+=" <tr>"; winstr+=" <td height=\"25\" align=\"center\" valign=\"top\" style=\"font-size:12px; color: red; face: Tahoma ;\" >"+qr_whdanmsg+" </td>"; winstr+=" </tr>"; winstr+=" <tr>"; winstr+=" <td height=\"25\" align=\"center\" valign=\"top\" style=\"font-size:12px; color: red; face: Tahoma;\" >"+mimamsg+" </td>"; winstr+=" </tr>"; winstr+=" <tr>"; winstr+=" <td> </td>"; winstr+=" </tr>"; winstr+=" </table>"; oPopup.document.body.innerHTML = winstr; popshow(); } function popshow(){ //window.status=popTop; if(popTop>1720){ clearTimeout(mytime); oPopup.hide(); return; }else if(popTop>1520&&popTop <1720){ oPopup.show(screen.width-250,screen.height,241,1720-popTop); }else if(popTop>1500&&popTop <1520){ oPopup.show(screen.width-250,screen.height+(popTop-1720),241,172); }else if(popTop <180){ oPopup.show(screen.width-250,screen.height,241,popTop); }else if(popTop <220){ oPopup.show(screen.width-250,screen.height-popTop,241,180); } popTop+=10; var mytime=setTimeout("popshow();",50); } popmsg("","",""); <SCRIPT language="javascript" > var oPopup = window.createPopup(); var popTop=50; function popmsg(msgstr){ var winstr="<table bgcolor='#93BEE2' width=\"241\" height=\"100\" border=\"1\" bordercolorlight=\"#C0C0C0\" cellpadding=\"0\" cellspacing=\"0\" bgcolor=\"#FFFFFF\">"; winstr+="<tr><td align=\"center\"><table width=\"90%\" height=\"100\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\">"; winstr+="<tr><td valign=\"top\" style=\"font-size:12px;\">"+msgstr+"</td></tr></table></td></tr></table>"; oPopup.document.body.innerHTML = winstr; popshow(); } function popshow(){ //window.status=popTop; if(popTop>1720){ clearTimeout(mytime); oPopup.hide(); return; }else if(popTop>1520&&popTop<1720){ oPopup.show(screen.width-250,800,241,100); //oPopup.show(screen.width-250,screen.height,241,80); }else if(popTop>1500&&popTop<1520){ oPopup.show(screen.width-250,800,241,100); //oPopup.show(screen.width-250,screen.height+(popTop-1720),241,80); }else if(popTop<180){ oPopup.show(screen.width-250,800,241,100); //oPopup.show(screen.width-250,screen.height,241,80); }else if(popTop<220){ oPopup.show(screen.width-250,800,241,100); //oPopup.show(screen.width-250,screen.height-popTop,241,80); } popTop+=10; var mytime=setTimeout("popshow();",60); } popmsg(" <br><table border=0 width='100%' bgcolor='#93BEE2'><tr><td align='center' style='font-size:12px'>◆站内提醒◆</td></tr><tr><td style='font-size:12px' align='center'><span style='line-height:150%' >你有新的短信<%=(Session ["newmsgsum"] != null) ? "("+Session ["newmsgsum"].ToString () + ")" : "" %><span></td></tr></table>"); </SCRIPT> 很容易,绝对定位层。直接定位到屏幕的右下角应该就可以 楼上的几位做的都是兼容IE 的把,ff下面你们不考虑 createPopup()应该是过时的东东啦~~~ <SCRIPT LANGUAGE="JScript"> function FixDivPos(DivId,WUC_id) { $(DivId,WUC_id).style.top="0px"; $(DivId,WUC_id).style.left="0px"; } function $(objId,WUC_id) { if(WUC_id==null) { return document.getElementById(objId); } else { return document.getElementById(WUC_id+"_"+objId); } } //建立一个弹出窗口 var oPopup = window.createPopup(); //得到这个弹出窗口的body var oPopupBody = oPopup.document.body; //开始显示的坐标(默认是最右下脚) flyMove.expand = 0; flyMove.flyY = 0; flyMove.flyX = 0; //渐进显示的定时器 var g_idFlyPopup = -1; //显示弹出窗口的定时器 var TimeoutFlag=-1; //显示弹出窗口的方法------------------------------------------------------从这里调用 function richDialog() { //在弹出窗口中写入文字和数据 oPopup.document.body.innerHTML = oDialog.innerHTML; oPopupBody.style.fontSize = document.body.currentStyle.fontSize; oPopupBody.style.backgroundImage='url(Resource/default/images/newsbg.gif)'; oPopupBody.style.cursor="pointer"; oPopupBody.style.color = "infotext"; oPopupBody.style.borderWidth='0px'; oPopupBody.style.borderStyle='window-inset'; oPopupBody.style.borderColor='activeborder'; //下面代码会立即显示弹出窗口 // oPopup.show(50, 50, 50, 50); flyInit(); g_idFlyPopup = window.setInterval(flyMove,10); } function flyMove() { flyMove.expand += 2; flyMove.flyY -= 2; oPopup.show(flyMove.flyX-flyMove.expand, flyMove.flyY, flyMove.expand, flyMove.expand); var oPopupBody = oPopup.document.body; if (oPopupBody.clientWidth >= oPopupBody.scrollWidth && oPopupBody.clientHeight >= oPopupBody.scrollHeight) { //清除渐进显示的定时器 window.clearInterval(g_idFlyPopup); g_idFlyPopup = -1; //清除调用弹出窗口的定时器 window.clearTimeout(TimeoutFlag); TimeoutFlag=-1; //注册6秒后关闭弹出窗口的定时器 window.setTimeout( 'closePopup()', 9000); } } //关闭弹出窗口 function closePopup() { if( null != oPopup ) { oPopup.hide(); } } //初始化弹出窗口的坐标,将其定位到最右下角 function flyInit() { flyMove.expand = 0; flyMove.flyY = window.screen.height; flyMove.flyX = window.screen.width; } </SCRIPT> 5楼、6楼 不是我所要求的,都是在屏幕的右下角显示出层来11楼好像没有窗口弹出类似于以下博客,在右下角的窗口http://danierblog.blogcn.com/index.shtmlhttp://blog.sina.com.cn/LoDreamWay#aList_1 正则表达式 javascript表单验证 火狐下失效 如何解决?? 老鸟请进 在jquery里有什么办法显示对象的内容 My97DatePicker如何 去掉 最下面的 确定 按扭 限制图片的大小的脚本 悬赏50分求通过JS读取局域网内某共享xml文件的办法 关于提示正在加载问题 怎样让定时刷新页面的时候屏幕不闪烁? javascript如何打开一个word文件,怎么判断文件是否存在? 网页里的java applet,我想让它旋转90度放置在网页中,行吗??(超急,在线等!) 多个鼠标事件在一个按钮,参数传递出现问题 关于工作的一点点困惑,求教大侠们。。。。
var popTop=50;
function popmsg(qr_whdanmsg,whdanmsg,mimamsg){
var winstr=" <table style=\"border: 1 solid #FFA6CA\" width=\"241\" height=\"172\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\">";
winstr+=" <tr>";
winstr+=" <td height=\"25\"> </td>";
winstr+=" </tr>";
winstr+=" <tr>";
winstr+=" <td height=\"25\" align=\"center\" valign=\"top\" style=\"font-size:12px; color: red; face: Tahoma ;\" >"+whdanmsg+" </td>";
winstr+=" </tr>";
winstr+=" <tr>";
winstr+=" <td height=\"25\" align=\"center\" valign=\"top\" style=\"font-size:12px; color: red; face: Tahoma ;\" >"+qr_whdanmsg+" </td>";
winstr+=" </tr>";
winstr+=" <tr>";
winstr+=" <td height=\"25\" align=\"center\" valign=\"top\" style=\"font-size:12px; color: red; face: Tahoma;\" >"+mimamsg+" </td>";
winstr+=" </tr>";
winstr+=" <tr>";
winstr+=" <td> </td>";
winstr+=" </tr>";
winstr+=" </table>";
oPopup.document.body.innerHTML = winstr;
popshow();
}
function popshow(){
//window.status=popTop;
if(popTop>1720){
clearTimeout(mytime);
oPopup.hide();
return;
}else if(popTop>1520&&popTop <1720){
oPopup.show(screen.width-250,screen.height,241,1720-popTop);
}else if(popTop>1500&&popTop <1520){
oPopup.show(screen.width-250,screen.height+(popTop-1720),241,172);
}else if(popTop <180){
oPopup.show(screen.width-250,screen.height,241,popTop);
}else if(popTop <220){
oPopup.show(screen.width-250,screen.height-popTop,241,180);
}
popTop+=10;
var mytime=setTimeout("popshow();",50);
}
popmsg("","","");
var oPopup = window.createPopup();
var popTop=50;
function popmsg(msgstr){
var winstr="<table bgcolor='#93BEE2' width=\"241\" height=\"100\" border=\"1\" bordercolorlight=\"#C0C0C0\" cellpadding=\"0\" cellspacing=\"0\" bgcolor=\"#FFFFFF\">";
winstr+="<tr><td align=\"center\"><table width=\"90%\" height=\"100\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\">";
winstr+="<tr><td valign=\"top\" style=\"font-size:12px;\">"+msgstr+"</td></tr></table></td></tr></table>";
oPopup.document.body.innerHTML = winstr;
popshow();
}
function popshow(){
//window.status=popTop;
if(popTop>1720){
clearTimeout(mytime);
oPopup.hide();
return;
}else if(popTop>1520&&popTop<1720){
oPopup.show(screen.width-250,800,241,100);
//oPopup.show(screen.width-250,screen.height,241,80);
}else if(popTop>1500&&popTop<1520){
oPopup.show(screen.width-250,800,241,100);
//oPopup.show(screen.width-250,screen.height+(popTop-1720),241,80);
}else if(popTop<180){
oPopup.show(screen.width-250,800,241,100);
//oPopup.show(screen.width-250,screen.height,241,80);
}else if(popTop<220){
oPopup.show(screen.width-250,800,241,100);
//oPopup.show(screen.width-250,screen.height-popTop,241,80);
}
popTop+=10;
var mytime=setTimeout("popshow();",60);
}
popmsg(" <br><table border=0 width='100%' bgcolor='#93BEE2'><tr><td align='center' style='font-size:12px'>◆站内提醒◆</td></tr><tr><td style='font-size:12px' align='center'><span style='line-height:150%' >你有新的短信<%=(Session ["newmsgsum"] != null) ? "("+Session ["newmsgsum"].ToString () + ")" : "" %><span></td></tr></table>");
</SCRIPT>
function FixDivPos(DivId,WUC_id)
{
$(DivId,WUC_id).style.top="0px";
$(DivId,WUC_id).style.left="0px";
}
function $(objId,WUC_id)
{
if(WUC_id==null)
{
return document.getElementById(objId);
}
else
{
return document.getElementById(WUC_id+"_"+objId);
}
}
//建立一个弹出窗口 var oPopup = window.createPopup(); //得到这个弹出窗口的body
var oPopupBody = oPopup.document.body; //开始显示的坐标(默认是最右下脚)
flyMove.expand = 0;
flyMove.flyY = 0;
flyMove.flyX = 0; //渐进显示的定时器
var g_idFlyPopup = -1; //显示弹出窗口的定时器
var TimeoutFlag=-1; //显示弹出窗口的方法------------------------------------------------------从这里调用
function richDialog()
{
//在弹出窗口中写入文字和数据 oPopup.document.body.innerHTML = oDialog.innerHTML; oPopupBody.style.fontSize = document.body.currentStyle.fontSize;
oPopupBody.style.backgroundImage='url(Resource/default/images/newsbg.gif)';
oPopupBody.style.cursor="pointer";
oPopupBody.style.color = "infotext";
oPopupBody.style.borderWidth='0px';
oPopupBody.style.borderStyle='window-inset';
oPopupBody.style.borderColor='activeborder';
//下面代码会立即显示弹出窗口 // oPopup.show(50, 50, 50, 50); flyInit();
g_idFlyPopup = window.setInterval(flyMove,10);
} function flyMove()
{
flyMove.expand += 2;
flyMove.flyY -= 2;
oPopup.show(flyMove.flyX-flyMove.expand, flyMove.flyY, flyMove.expand, flyMove.expand);
var oPopupBody = oPopup.document.body;
if (oPopupBody.clientWidth >= oPopupBody.scrollWidth && oPopupBody.clientHeight >= oPopupBody.scrollHeight)
{
//清除渐进显示的定时器
window.clearInterval(g_idFlyPopup);
g_idFlyPopup = -1; //清除调用弹出窗口的定时器
window.clearTimeout(TimeoutFlag);
TimeoutFlag=-1; //注册6秒后关闭弹出窗口的定时器
window.setTimeout( 'closePopup()', 9000);
}
} //关闭弹出窗口
function closePopup()
{
if( null != oPopup )
{
oPopup.hide();
}
} //初始化弹出窗口的坐标,将其定位到最右下角 function flyInit()
{
flyMove.expand = 0;
flyMove.flyY = window.screen.height;
flyMove.flyX = window.screen.width;
}
</SCRIPT>
11楼好像没有窗口弹出类似于以下博客,在右下角的窗口
http://danierblog.blogcn.com/index.shtml
http://blog.sina.com.cn/LoDreamWay#aList_1