<?xml version="1.0" encoding="iso-8859-1"?>
<rss version="2.0">
<channel>
  <title>Linux Format forums</title>
  <link>http://www.linuxformat.com/forums/index.php</link>
  <description>Help, discussion, magazine feedback and more</description>
  <language>english</language>
  <copyright>(c) Copyright Sat May 18, 2013 9:37 am by Linux Format forums</copyright>
  <managingEditor>webmaster@linuxformat.com</managingEditor>
  <webMaster>webmaster@linuxformat.com</webMaster>
  <pubDate>Sat May 18, 2013 9:37 am</pubDate>
  <lastBuildDate>Sat May 18, 2013 9:37 am</lastBuildDate>
  <docs>http://backend.userland.com/rss</docs>
  <generator>phpBB2 RSS Syndication Mod by Lucas</generator>
  <ttl>1</ttl>

  <image>
    <title>Linux Format forums</title>
    <url></url>
    <link>http://www.linuxformat.com/forums/</link>
    <description>Help, discussion, magazine feedback and more</description>
  </image>

                                      <item>
                                        <title>Practical PHP Programming -- Can't open remote file</title>
                                        <link>http://www.linuxformat.com/forums/viewtopic.php?p=91882#91882</link>
                                        <description>&lt;br /&gt;
                                      Author: &lt;a href='http://www.linuxformat.com/forums/profile.php?mode=viewprofile&amp;u=65997'&gt;chriswadams&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;
                                      Posted: Thu Aug 12, 2010 1:47 am&lt;br /&gt;&lt;br /&gt;
                                      &lt;br /&gt;&lt;br /&gt;
                                      Hey everyone --&lt;br /&gt;
&lt;br /&gt;
I'm working through the &amp;quot;Practical PHP Programming&amp;quot; book on TuxRadar, and found this snippet of code (at &lt;a href=&quot;http://www.tuxradar.com/practicalphp/8/14/0&quot; rel=&quot;nofollow&quot; target=&quot;_blank&quot;&gt;http://www.tuxradar.com/practicalphp/8/14/0&lt;/a&gt;):&lt;br /&gt;
&lt;br /&gt;
&lt;/span&gt;&lt;table width=&quot;90%&quot; cellspacing=&quot;1&quot; cellpadding=&quot;3&quot; border=&quot;0&quot; align=&quot;center&quot;&gt;&lt;tr&gt; 	  &lt;td&gt;&lt;span class=&quot;genmed&quot;&gt;&lt;b&gt;Code:&lt;/b&gt;&lt;/span&gt;&lt;/td&gt;	&lt;/tr&gt;	&lt;tr&gt;	  &lt;td class=&quot;code&quot;&gt;&lt;br /&gt;
&amp;lt;?php&lt;br /&gt;
&amp;nbsp; &amp;nbsp; $slash = fopen&amp;#40;&amp;quot;http&amp;#58;//www.slashdot.org&amp;quot;, &amp;quot;r&amp;quot;&amp;#41;;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; $site = fread&amp;#40;$slash, 200000&amp;#41;;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; fclose&amp;#40;$slash&amp;#41;;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; print $site;&lt;br /&gt;
?&amp;gt; &lt;br /&gt;
&lt;/td&gt;	&lt;/tr&gt;&lt;/table&gt;&lt;span class=&quot;postbody&quot;&gt;&lt;br /&gt;
&lt;br /&gt;
The book says:&lt;br /&gt;
&lt;br /&gt;
&lt;/span&gt;&lt;table width=&quot;90%&quot; cellspacing=&quot;1&quot; cellpadding=&quot;3&quot; border=&quot;0&quot; align=&quot;center&quot;&gt;&lt;tr&gt; 	  &lt;td&gt;&lt;span class=&quot;genmed&quot;&gt;&lt;b&gt;Quote:&lt;/b&gt;&lt;/span&gt;&lt;/td&gt;	&lt;/tr&gt;	&lt;tr&gt;	  &lt;td class=&quot;quote&quot;&gt;&lt;br /&gt;
&amp;quot;Try saving the above code into a file, &amp;quot;openremote.php&amp;quot;, and loading it into your web browser - you should see Slashdot displayed&amp;quot;, &lt;br /&gt;
&lt;/td&gt;	&lt;/tr&gt;&lt;/table&gt;&lt;span class=&quot;postbody&quot;&gt;&lt;br /&gt;
&lt;br /&gt;
but when I did that, I got nothing but a blank screen. I changed &amp;quot;www.slashdot.org&amp;quot; to a local file, and that worked fine, but no non-local files will display (except for one site, &lt;a href=&quot;http://www.townhall.com/columnists,&quot; rel=&quot;nofollow&quot; target=&quot;_blank&quot;&gt;http://www.townhall.com/columnists,&lt;/a&gt; which only displayed the blue background of the title bar).&lt;br /&gt;
&lt;br /&gt;
Does anyone have any suggestions as to why this code isn't working? Any input would be appreciated.&lt;br /&gt;
&lt;br /&gt;
chriswadams.</description>
                                        <comments>http://www.linuxformat.com/forums/viewtopic.php?p=91882#91882</comments>
                                        <author>chriswadams</author>
                                        <pubDate>Thu Aug 12, 2010 1:47 am</pubDate>
                                        <guid isPermaLink="true">http://www.linuxformat.com/forums/viewtopic.php?p=91882#91882</guid>
                                      </item></channel></rss>