Hi there,
I’m new to PHP and I am trying to get the below code to update my DB. I am however receiving the following error message. Any support would be much appreciated…Parse error: syntax error, unexpected ‘"’, expecting identifier (T_STRING) or variable (T_VARIABLE) or number (T_NUM_STRING) in C:\xampp\htdocs\babysitter\addprocess.php on line 9
<?php $server = "localhost"; $dbuser = "root"; $password = ""; $link = mysqli_connect($server,$dbuser,$password); mysqli_select_db($link,"babysitter"); $sql = "INSERT INTO babysitter (firstName, lastName, age, gender, nationality) values ($_post["firstname"],$_post["lastname"],$_post["age"],$_post["gender"],$_post["nationality"])"; mysqli_query($link,$sql); mysqli_close($link);