HTML stops at a PHP script made to connect to a mysql database. No errors printed.

Posted by DavidR on Stack Overflow See other posts from Stack Overflow or by DavidR
Published on 2010-06-07T00:19:12Z Indexed on 2010/06/07 0:22 UTC
Read the original article Hit count: 222

Filed under:
|

I'm trying to set up a login script for PHP using the tutorial on this site. The problem is that the site stops when it hits these lines, no error, no text:

<?php
$conn = mysql_connect('localhost', 'root', 'password') or die('error line7' . mysql_error());
mysql_select_db('mydb', $conn) or die('error line8' . mysql_error());
?>

If I take out these lines, the rest of the html runs perfectly. I've double checked my passwords and everything, nothing is working. I know very little about php and mysql other than what I've learned trying to set this up.

© Stack Overflow or respective owner

Related posts about php

Related posts about login-script