Basically you have to do math calculations in JavaScript based on the browser's window size. I think the syntax is something like screen.width, screen.height. Or maybe that is for the screen size. Anyway, the syntax for the browser window is similar.
Then use JavaScript/DHTML to tell the layer(s) exactly where you wante them situated. Using CSS you have to tell the layers that they are "position:absolute" and then set the "top" and "left" using your DHTML.
Sorry I don't have any code for you, lemme know if this is good enough.
I think it's a great way to do it. But I would say look at your web stats first. When I do this kind of site, I do it when 95% or better use Internet Explorer, cuz Netscape doesn't have great support for it, and customizing Netscape doubles the amount of code you have to write because it treats layers differently.
(Netscape uses document.layers and IE uses document.all and the HTML DIV tag)
I did something like this, only with a window (for my friend's band). ~800x600 window launches in center. Code is in external file, let me know if you can't find.
I see you were planning on a layer... you could adapt my code to layerrs (I'd help, but not much experience with layers), you could have it open automatically. I think layers are your best bet.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.