ok. just got back from being bedridden for 2 weeks.. (uhg. hate bein sick. got hit way to hard.) and i am back to this issue:
mysql and php… a match made in hell.(well not really but i cant get it to work.)
i get free SQL hosting and i have a php host too. so heres the page: register.html and register.php
register.html
[code] <form action=”register.php” method=”POST”>
<p class=”MainText” style=”text-align:center;”>Username: <input type=”text” name=”username” size=”11″ /><br /> Password: <input type=”password” name=”password” size=”11″ /><br /> Email: <input type=”text” name=”email” size=”11″ /><br /></p>
<p class=”MainText” style=”text-align:center;”><input class=”Submit” type=”submit” value=”Submit” /></p>
</form>
and register.php
[code]<?php
$username = “$_POST[‘username’]”;
$password = “$_POST[‘password’]”;
$email = “$_POST[’email’]”;
$host = “sorry”;
$dbusername = “sorry”;
$dbpassword = “sorry”;
$database = “sorry”;
$signup = “INSERT INTO Users (id, created, username, userpass, email) VALUES (”, NOW(), ‘$username’, ‘$password’, ‘$email’)”;
$test = “INSERT INTO `Users` (`id`, `created`, `username`, `userpass`, `email`) VALUES (”, ‘666’, ‘xaxei’, ‘pass’, ‘[email protected]’)”;
$create = “CREATE TABLE `test` (`bob` TINYINT NOT NULL )”;
mysql_connect($host, $username, $password);
mysql_select_db($database);
mysql_query($test);
mysql_close();
echo “Username: ” $_POST[‘username’];<br />
echo “Password: ” $_POST[‘password’];<br />
echo “Email: ” $email;<br />
?>
pyro I don’t see why this wont work. its annoying me. if i tell it to do $test it wont work, $create wont work and $signup wont work so im confused. it must be something stupid and im sure you’ll be able to tell me what it is! (please?) its really annoying me π‘ … anyone else can help too=P
also, i use phpmyadmin to check the database and i can give u all the passwords and information if u need to fix this cause i have no clue why it wont work and iv been working on it for a while and with this on top of being sick i just want to give up!
much thanks in advance