开发者

What's the best way to create a frame with a fixed interior dimension and fluid exterior dimension?

I plan on creating a layer of absolutely positioned elements that is moved around with jQuery. I need to create a frame, on top of and around this layer, that has a fixed viewport in the center and edges which flow to the e开发者_Go百科dges of the browser viewport, creating a mask that hides portions of the main layer that is moved around underneath.

Currently I am using four divs to create the frame and setting their dimensions onload with a jQuery statement like this:

`$("#viewportLeft,#viewportRight").css("width",($(window).width()-[maskViewportWidth])/2);`

Any better ideas?


Why not just move a div around inside another div?

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜