当我尝试注册为用户时,为什么我的register.php
文件不能执行任何操作?我错过了什么吗?我已经确信我连接到使用config.db
为什么我的php代码不能做任何事情?
我的注册页面mysql数据库:
<html>
<head>
<title> Register!</title>
</head>
<body>
<form action="register.php" method="POST">
<h1>Signup!</h1>
<p>Create an account:</p>
<div>
<label for="name">Name:</label>
<input type="text" id="name" name="firstname" value="" placeholder="First Name" class="login" />
</div> <!-- /field -->
<div>
<label for="email">Email Address:</label>
<input type="text" id="email" name="email" value="" placeholder="Email" class="login"/>
</div> <!-- /field -->
<div>
<label for="pass">Password:</label>
<input type="password" id="password" name="password" value="" placeholder="Password" class="login"/>
</div> <!-- /field -->
<div>
<label for="confirm_password">Confirm Password:</label>
<input type="password" id="confirmpassword" name="confirm_password" value="" placeholder="Confirm Password" class="login"/>
</div> <!-- /field -->
<input type="submit">Register</button>
</form>
</div> <!-- /content -->
</div> <!-- /account-container -->
</body>
</html>
我的PHP文件
定义任何东西.. – CharliePrynn
[请不要在新代码中使用'mysql_ *'函数](http://bit.ly/phpmsql)。他们不再被维护[并被正式弃用](https://wiki.php.net/rfc/mysql_deprecation)。看到[红框](http://j.mp/Te9zIL)?学习[*准备的语句*](http://j.mp/T9hLWi),并使用[PDO](http://php.net/pdo)或[MySQLi](http://php.net/ mysqli) - [这篇文章](http://j.mp/QEx8IB)将帮助你决定哪个。如果你选择PDO,[这里是一个很好的教程](http://j.mp/PoWehJ)。 **您也开放给[SQL注入](http://stackoverflow.com/q/60174)** –
请[在学习PDO](http://php.net/pdo)之前,为时已晚,我可以''语法错误附近'吨压力这就够了'' –