PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
built-in file request have been in for quite some time, I'm not sure what you're referring to that's in 5, but not in 4 for this that really matters..
file_get_contents() can request an external file (provided url wrappers are turned on). Display of it is quite simple, depending on how you want to show it.. you could simply send a text/plain header to the browser and the found text, or use htmlentities() to display the code inside pretty stuff.
You get the error because you don't have a clue what fsockopen is really doing.. It would require you to open a socket on slashdot.org and then fwrite a GET /slashdot.xml...
But as feyd already mentionned, simply use file_get_contents / file (with the HTTP(S) wrappers enabled) so you don't have to write the HTTP stuff yourself.
If you are going to server the data from the xml feed, you should make sure that you send out the appropriate Content-Type header too. Because i've seen XMLHTTP choke on that.