By the way, js4mIRC wouldn't have helped you because it doesn't have any support for DOM access or making web requests. Sockets is the right approach. You want to make a web request for the page and, based on how the page is structured, either pull it from the associated CSS file or directly from HTML.

If you're programming this for a specific website, you may be able to shortcircuit a lot of those requests by making assumptions about where that background image URL is being stored (which CSS file, for instance). But if you're trying to make a generic function that can pull a background image from ANY website, note that this is actually not a trivial task and requires being able to parse the entire DOM, CSS, and in some cases, evaluate JavaScript. In other words, you need a full browser.

Note that someone may come in here and lend you a COM ($com) script to do this more easily, as $com() allows you to run an IE browser and pull information from the DOM. This is the foundation of SReject's JSON script, so if you are knowledgeable with COM / JS, you may want to look at that approach.


- argv[0] on EFnet #mIRC
- "Life is a pointer to an integer without a cast"