Jump to content

[SOLVED] facebook-like popup??


ohdang888

Recommended Posts

Something like this?

<html>
<head>
<script language="JScript">
function startDrag(e)
{
var offsetX = event.clientX-parseInt(e.style.left);
var offsetY = event.clientY-parseInt(e.style.top);
document.onmousemove = function()
{
	e.style.left = event.clientX-offsetX;
	e.style.top = event.clientY-offsetY;
}
document.onmouseup=function()
{
	document.onmousemove=null;
}
}
</script>
</head>
<bodY>
<div STYLE="position:absolute;width:100px;height:100px;background-color:#0000FF;left:0px;top:0px" onmousedown="startDrag(this)"></div>
</body>
</html>

you probably mean a modal its a layer above the normal page with the background faded

I have only seen them with javascript frameworks though here is a couple of links

using prototype

http://prototype-window.xilinus.com/

 

using mootools

http://www.e-magine.ro/web-dev-and-design/36/moodalbox/

 

jquery

http://malsup.com/jquery/block/index-old.html#dialog

 

hope that helps

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.