This is my first time trying to build a website, and I had the design idea that instead of an image or a color I let the viewer see their desktop. There are plenty of discussions online how to make the browser window transparent from a browser config perspective, but I have either not found any for a webdesign perspective or I have not looked good enough. Eitherway can you show me how or the direktion? Thank you.
I dont think you can operate outside the intended sandbox of the browser.
I don’t want to leave the sandbox. Just to have an alpha-channel on the background color/image.
and that’s operating outside the sandbox
I believe you can’t access it through the browser
have you ever seen such a website? we could see the source
It requires that you render the image of the wallpaper into the HTML. then put a “transparency effect”. You are not supposed to “retrieve” anything from the desktop operating system then render into the webpage. Otherwise, you might as well retrieve my porn collection, password manager vault, sensitive files, etc.
First of all, either the OS itself or the specific browser would need some kind of API to allow it to be made transparent, and that doesn’t exist.
And secondly, even if that were possible, it wouldn’t guarantee that it actually showed the Desktop Background because who knows what’s behind the browser window.
Windows used to store the currently used wallpaper in a fixed location as a cacheed copy of whatever you selected, but I don’t know if that’s still the case. If it were, theoretically you could maybe hardcode that path in a
file:// url? IDK.
That said… optimising that page for anything would be a nightmare because you don’t know what people have as their background and what works with one won’t necessarily work with another.
It’s just a bad idea all around.