what you are trying to do will not work.
from the manual on [man]include[/man]:
If "URL fopen wrappers" are enabled in PHP (which they are in the default configuration), you can specify the file to be included using a URL (via HTTP or other supported wrapper - see Appendix M for a list of protocols) instead of a local pathname. If the target server interprets the target file as PHP code, variables may be passed to the included file using a URL request string as used with HTTP GET. This is not strictly speaking the same thing as including the file and having it inherit the parent file's variable scope; the script is actually being run on the remote server and the result is then being included into the local script.
when a remote file is included it will only receive the output sent from the remote server, not the variable scope of the remote file. think about the security implications of that if it did work the way you are expecting. let's say my site at http://www.mysite.com has a file in the document root called "include.php" which looks like this:
<?php
$hostname = 'localhost';
$username = 'myusername';
$password = 'mypassword';
mysql_connect($hostname, $username, $password);
?>
then on your server at http://www.yoursite.com you have a script that looks like this:
<?php
include('http://www.mysite.com/include.php');
echo $username;
echo $password;
?>
would you expect to see my username and password?