MySQL和PHP。我的桌子不存在

时间:2017-03-12 05:40:07

标签: php html mysql xampp dreamweaver

所以我在phyMyAdmin中创建了一个数据库,然后用我的html文件对其进行编码,然后用chrome打开它...它说 表'forum.form_tabl'不存在 发生了什么,我该怎么办? 这是代码

    <?php

session_start();
require"db_connect.php";
$sql= "SELECT forum_id,forum_name FROM form_tabl";

?>
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>Untitled Document</title>
</head>

<body>
<div id="container">
	<table>
		<?php if($query->num_rows !==0);
		while($row = $query->fetch()):
		?>
		<tr><td><a href="forum.php"?id = <?php echo $forum_id?>"><?php echo $f_name;?></a>
			</td></tr>
			<?php endwhile;T_ENDIF;
		?>
	</table>
</div>


</body>
</html>[enter image description here][1]
    //THE OTHER .PHP file is db_connect.php where i put the actual one

    <?php

    $db = mysqli_connect("localhost","root","","forum") or die("ERROR! With Connection")
    ?>

enter image description here

1 个答案:

答案 0 :(得分:1)

**�NUMPYF{'descr': '<f8', 'fortran_order': False, 'shape': (0,), }            **