javascript - why my database cannot connect ? but this is my connect.php -


<?php                        mysql_connect($localhost, $loyopcom_okeball, $loyopcom_okeball) or die("cannot connect");      $result = mysql_select_db($loyopcom_okeball) or die("cannot select db"); ?> 

enter image description here

try use

$link =mysql_connect($localhost, $loyopcom_okeball, $loyopcom_okeball) or die("cannot connect");   

and

mysql_select_db('database_name', $link); 

besides, if use version higher 5.0,because server closed, should use

mysqli_connect($localhost, $loyopcom_okeball, $loyopcom_okeball); mysqli_select_db($link,'database_name'); 

Comments

Popular posts from this blog

javascript - Chart.js (Radar Chart) different scaleLineColor for each scaleLine -

apache - Error with PHP mail(): Multiple or malformed newlines found in additional_header -

java - Android – MapFragment overlay button shadow, just like MyLocation button -