当前位置:编程学习 > asp >>

在右下角弹出提示

答案:public static string GetMsg(string strDescription)
{
string strScript = "<script language=\"javascript\">";
if(strDescription != "")
{
strScript += "document.write(\"<div id='popmsg' style='position:absolute;right:0px;bottom:0px;width:260px;height:165px;z-index:1;padding:20px 20px 20px 20px;word-break:break-all;text-align:left;background-image: url(images/popmsgbg.gif);'>"+strDescription+"</div>\");";

strScript += "j=3;"+
"function popClose() {"+
" j -= 1;"+
" if (j > 0){setTimeout(\"popClose()\",1000);}"+
" else{popmsg.style.display=\"none\";}"+
"}";

strScript += "popClose();";

}
strScript += "</script>";

return strScript;
}


上一个:ASP在线升级类文件
下一个:用asp写一个简单的加密和解密的类。。。。

CopyRight © 2022 站长资源库 编程知识问答 zzzyk.com All Rights Reserved
部分文章来自网络,