What would cause & in URLS to automatically be converted to &amp;?
<p>Im a little stuck. I developed a script and for some reason it is converting <code>&amp;</code> in URLs to <code>&amp;amp;</code> automatically.</p>

<p>This is the line that is causing the issue:</p>

<pre><code>$accessToken = file_get_contents('https://graph.facebook.com/oauth/access_token?client_id=' . APPID . '&amp;redirect_uri=' . APPURL . 'callback.php&amp;client_secret=' . APISECRET . '&amp;code=' . $_REQUEST['code']);
</code></pre>

<p>And this is what the error report is returning:</p>

<pre><code>[20-Jul-2010 15:47:35] PHP Warning:  file_get_contents(https://graph.facebook.com/oauth/access_token?client_id=xxxxxxx&amp;amp;redirect_uri=http://apps.facebook.com/xxxxx/callback.php&amp;amp;client_secret=xxxxxx&amp;amp;code=) [&lt;a href='function.file-get-contents'&gt;function.file-get-contents&lt;/a&gt;]: failed to open stream: HTTP request failed! HTTP/1.0 400 Bad Request
</code></pre>

<p>in /home/pk1no/public_html/video/callback.php on line 8</p>

<p>The funny thing is the same script works on my Joyent dedicated, but not on my HostGator dedicated. I'm a little baffled by it.</p>
