Abyssal
2007-05-24 22:17:14
Today I setup MySQL, Apache and PHP on my computer.
Yes, PHP and apache are installed correctly they work <3
But, on my command prompt i type
~~
Also, heres my PHP file:
[php]
<html>
<head> <title>MySQL Connection Test</title> </head>
<body>
<h2>
<?php
$connection = mysql_connect("localhost", "root", "")
or die("Unable to connect.");
echo("Congratulations! Connected to MySQL!");
?>
</h2>
</body>
</html>
[/php]
And nothing happens! It's like it fails at the php part. Doesn't 'die' or anything… Why?!
Yes, PHP and apache are installed correctly they work <3
But, on my command prompt i type
C:\mysql\bin\mysql
And it gives an invalid pass error, so I do this:
C:\mysql\bin\mysql -u root
And it works. Why?~~
Also, heres my PHP file:
[php]
<html>
<head> <title>MySQL Connection Test</title> </head>
<body>
<h2>
<?php
$connection = mysql_connect("localhost", "root", "")
or die("Unable to connect.");
echo("Congratulations! Connected to MySQL!");
?>
</h2>
</body>
</html>
[/php]
And nothing happens! It's like it fails at the php part. Doesn't 'die' or anything… Why?!