Hi. At my job I constantly need to be up to the moment on the weather, and I want to create a display that will combine important elements from different weather services onto one screen that I can hang on the wall.
What are need are basic <div>'s from several different sites. I know I could use iframes but I don’t want to display entire sites, just the elements I need from them. Then I want to be able to have some DOM control over them (e.g. setting refresh time for each element).
Any ideas on what would be the best way to go about this? Any suggestions would be greatly appreciated. Thanks!
You might have to look into Ajax for that, but that would be a topic for the JavaScript forum. We could move this thread if you like.
yes, I assumed some javascript would be involved, but I didn’t know what forum would be appropriate. I’ve read that jQuery is good for DOM control but am still not sure what would be the best technique for doing this project. Please move this to the javacript forum if that would be better. Thanks.
[Thread moved to JS forum.]
Javascript doesn’t allow you to work with other sites without their permission.
With PHP though, you can use something called Curl to retrieve the contents of a web page, from which you can then retrieve the parts that you require.
The typical technique is that an ajax request is sent to a PHP script, which retrieves the data and sends it back to your request.