$result = mysql_qurey not working

I was trying to insert some data to my db with a php script.

This line below does not work :neutral:

$result = mysql_query(“INSERT INTO Main(Email, PhoneNumber, Password, UserName) VALUES(‘$email’, ‘$phoneNumber’, ‘$password’, ‘$userName’)”);

mysql_query is very outdated and only through a collection on hacks can it be used on our hosting anyways. I would highly recommend to switch over to MySQLi or PDO to connect to your database, because it’s better supported and more secure.