diff --git a/gw-create.php b/gw-create.php index 5dba328..3e5e4db 100644 --- a/gw-create.php +++ b/gw-create.php @@ -6,9 +6,40 @@ Character creation isn\'t enabled yet!
'; -echo 'Return to home.'; +echo '
Character creation isn\'t enabled yet!
Your userid is ' . $userid . ''; +if ($createnew === "1"){ + $cname = mysqli_real_escape_string($con, $_POST['cname']); + $bdate = mysqli_real_escape_string($con, $_POST['bdate']); + $profid = mysqli_real_escape_string($con, $_POST['professionid']); + $sqlcreate = "INSERT INTO `playername` (charname, birthdate, userid, professionid) VALUES ('$cname', '$bdate', $userid, $profid)"; + echo 'Character creation database insertion code here'; +} else { + echo 'Form creation code goes here'; + echo '
'; + echo 'Character name:
'; + echo 'Birthdate:
'; + echo ''; + $sqlprofession = "SELECT * FROM (SELECT * FROM listruneprofessions ORDER BY runeprofid DESC LIMIT 10) sub ORDER BY runeprofid ASC"; + if (!$result = $con->query($sqlprofession)){ + die ('There was an error running the query [' . $con->error . ']'); + } + echo 'Profession:

'; + echo '
'; +} ?> +

+Return to home. +
\ No newline at end of file