做网站收获了什么,wordpress去掉导航栏,未来电子商务发展前景,陕西江川建设有限公司公司网站Ajax的到来让B/S中的客户端中开发有火了一把#xff0c;网上出现了很多优秀的开源框架和UI#xff0c;比较著名了有prototype#xff0c;YUI#xff0c;GWT等#xff0c;但很多时候发现这些东西很难用到你的系统之中#xff0c;有时候你的系统仅仅需要实现一两个UI功能网上出现了很多优秀的开源框架和UI比较著名了有prototypeYUIGWT等但很多时候发现这些东西很难用到你的系统之中有时候你的系统仅仅需要实现一两个UI功能如果把整个架构都引入进来是不现实的。所以很多时候是需要自己动手去做一些工作。 现在弹出窗口在B/S系统中很受青睐它有美观性和易用性等诸多特点比如我用的sina 博客登陆窗口就是应用了弹出窗口。以前我们做弹出窗口只用一个window.open()搞定但后来发现这种窗口有很多弊端首先是界面的美观性差其次是与主页面的交互性差只有一个window.opener引用主页面。所以在开发过程中要自己动手做一些这方面的事情。 于是很多人选择了用Div来实现但出窗口功能用css来控制外观。但是这对开发人员提出更高要求窗口的定位、拖动、与主页面的交互等。。。 !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.0 Transitional//EN
HTML
HEAD
TITLE New Document /TITLE
META NAMEGenerator CONTENTEditPlus
META NAMEAuthor CONTENT
META NAMEKeywords CONTENT
META NAMEDescription CONTENT
style typetext/css
.winFrame{position:absolute;border: outset gray 1px;height:400;width:500;
}
.winTitle{position:absolute;border-bottom:1px solid black;width:100%;height:20px;cursor:move;
}
.winContent{position:absolute;top:30px;width:100%padding: 10px;overflow: auto;
}
/style
SCRIPT LANGUAGEJavaScriptfunction beginDrag(elem,event){var deltaX event.clientX - parseInt(elem.style.left);var deltaY event.clientY - parseInt(elem.style.top);document.attachEvent(onmousemove,moveHandler);document.attachEvent(onmouseup,upHandler);event.cancelBubble true;event.returnValue false;function moveHandler(e){if(!e)e window.event;elem.style.left (e.clientX - deltaX) px;elem.style.top (e.clientY - deltaY) px;e.cancelBubble true;}function upHandler(e){if(!e)e window.event;document.detachEvent(onmousemove,moveHandler);document.detachEvent(onmouseup,upHandler);e.cancelBubble true;}}
/SCRIPT
/HEADdiv classwinFrame styleleft:50px;top:50px;div classwinTitle onmousedownbeginDrag(this.parentNode,event); 标题 /divdiv classwinContent内容/div/div
BODY
/BODY
/HTML 转载于:https://www.cnblogs.com/sherlockholmes/p/5286966.html